diff --git a/src/app/AppRegistry.tsx b/src/app/AppRegistry.tsx index 86959b7e8b8..09aed76e88b 100644 --- a/src/app/AppRegistry.tsx +++ b/src/app/AppRegistry.tsx @@ -287,12 +287,18 @@ function register( } export interface ViewOptions { + // TODO: Remove this once we the old infra code gets removed modalPresentationStyle?: "fullScreen" | "pageSheet" | "formSheet" + // @deprecated Use screenOptions.headerShown instead + // TODO: Remove this once we the old infra code gets removed hasOwnModalCloseButton?: boolean alwaysPresentModally?: boolean + // @deprecated Use screenOptions.headerShown instead + // TODO: Remove this once we the old infra code gets removed hidesBackButton?: boolean hidesBottomTabs?: boolean fullBleed?: boolean + // TODO: Remove this once we the old infra code gets removed ignoreTabs?: boolean // If this module is the root view of a particular tab, name it here isRootViewForTabName?: BottomTabType @@ -308,11 +314,15 @@ export type ModuleDescriptor = { options: ViewOptions } -function reactModule( - Component: React.ComponentType, - options: ViewOptions = {}, +function reactModule({ + Component, + options = {}, + Queries, +}: { + Component: React.ComponentType + options?: ViewOptions Queries?: GraphQLTaggedNode[] -): ModuleDescriptor { +}): ModuleDescriptor { return { type: "react", options, Component, Queries } } @@ -322,7 +332,6 @@ function defineModules(obj: Record) { } const artQuizScreenOptions = { - hidesBackButton: true, fullBleed: true, screenOptions: { gestureEnabled: false, @@ -332,515 +341,891 @@ const artQuizScreenOptions = { export type AppModule = keyof typeof modules export const modules = defineModules({ - Activity: reactModule(ActivityScreen, { - fullBleed: true, - hidesBackButton: true, - hidesBottomTabs: true, - }), - ActivityItem: reactModule(ActivityItemScreenQueryRenderer, { - fullBleed: true, - hidesBackButton: true, - hidesBottomTabs: true, - }), - About: reactModule(About, { - screenOptions: { - headerTitle: "About", - }, - }), - AddMyCollectionArtist: reactModule(AddMyCollectionArtist, { - hidesBackButton: true, - }), - AlertArtworks: reactModule(AlertArtworks, { - fullBleed: true, - hidesBackButton: true, - hidesBottomTabs: true, - }), - ArtQuiz: reactModule(ArtQuiz, { ...artQuizScreenOptions, hidesBottomTabs: true }), - ArtQuizResults: reactModule(ArtQuizResults, { - fullBleed: true, - hidesBackButton: true, - screenOptions: { - animationTypeForReplace: "pop", - }, - }), - Article: reactModule(ArticleScreen, { - fullBleed: true, - hidesBackButton: true, - }), - ArticleSlideShow: reactModule(ArticlesSlideShowScreen, { - fullBleed: true, - hidesBackButton: true, - hidesBottomTabs: true, - }), - Articles: reactModule( - ArticlesScreen, - { - fullBleed: true, - hidesBackButton: true, - }, - [ArticlesScreenQuery] - ), - Artist: reactModule(ArtistQueryRenderer, { fullBleed: true, hidesBackButton: true }, [ - ArtistScreenQuery, - ]), - ArtistShows: reactModule(ArtistShows2QueryRenderer), - ArtistArticles: reactModule(ArtistArticlesQueryRenderer, { - fullBleed: true, - hidesBackButton: true, - }), - ArtistSeries: reactModule(ArtistSeriesQueryRenderer, { - fullBleed: true, - hidesBackButton: true, - }), - Artwork: reactModule( - ArtworkScreen, - { - hidesBackButton: true, + Activity: reactModule({ + Component: ActivityScreen, + options: { + fullBleed: true, + hidesBottomTabs: true, + screenOptions: { + headerShown: false, + }, + }, + }), + ActivityItem: reactModule({ + Component: ActivityItemScreenQueryRenderer, + options: { + fullBleed: true, + hidesBottomTabs: true, + screenOptions: { + headerShown: false, + }, + }, + }), + About: reactModule({ + Component: About, + options: { + screenOptions: { + headerTitle: "About", + }, + }, + }), + AddMyCollectionArtist: reactModule({ + Component: AddMyCollectionArtist, + options: { + screenOptions: { + headerShown: false, + }, + }, + }), + AlertArtworks: reactModule({ + Component: AlertArtworks, + options: { + fullBleed: true, + hidesBottomTabs: true, + screenOptions: { + headerShown: false, + }, + }, + }), + ArtQuiz: reactModule({ + Component: ArtQuiz, + options: { ...artQuizScreenOptions, hidesBottomTabs: true }, + }), + ArtQuizResults: reactModule({ + Component: ArtQuizResults, + options: { + fullBleed: true, + screenOptions: { + animationTypeForReplace: "pop", + headerShown: false, + }, + }, + }), + Article: reactModule({ + Component: ArticleScreen, + options: { + fullBleed: true, + screenOptions: { + headerShown: false, + }, + }, + }), + ArticleSlideShow: reactModule({ + Component: ArticlesSlideShowScreen, + options: { + fullBleed: true, hidesBottomTabs: true, + screenOptions: { + headerShown: false, + }, + }, + }), + Articles: reactModule({ + Component: ArticlesScreen, + options: { + fullBleed: true, + screenOptions: { + headerShown: false, + }, + }, + Queries: [ArticlesScreenQuery], + }), + Artist: reactModule({ + Component: ArtistQueryRenderer, + options: { + fullBleed: true, + screenOptions: { + headerShown: false, + }, + }, + Queries: [ArtistScreenQuery], + }), + ArtistShows: reactModule({ Component: ArtistShows2QueryRenderer }), + ArtistArticles: reactModule({ + Component: ArtistArticlesQueryRenderer, + options: { + fullBleed: true, + screenOptions: { + headerShown: false, + }, + }, + }), + ArtistSeries: reactModule({ + Component: ArtistSeriesQueryRenderer, + options: { + fullBleed: true, + screenOptions: { + headerShown: false, + }, + }, + }), + Artwork: reactModule({ + Component: ArtworkScreen, + options: { + hidesBottomTabs: true, + screenOptions: { + headerShown: false, + }, + }, + Queries: [ArtworkScreenQuery], + }), + ArtworkMedium: reactModule({ + Component: ArtworkMediumQueryRenderer, + options: { + fullBleed: true, + alwaysPresentModally: !unsafe_getFeatureFlag("AREnableNewNavigation"), + modalPresentationStyle: !unsafe_getFeatureFlag("AREnableNewNavigation") + ? "fullScreen" + : undefined, + }, + }), + ArtworkAttributionClassFAQ: reactModule({ + Component: ArtworkAttributionClassFAQQueryRenderer, + options: { + fullBleed: true, + alwaysPresentModally: !unsafe_getFeatureFlag("AREnableNewNavigation"), + modalPresentationStyle: !unsafe_getFeatureFlag("AREnableNewNavigation") + ? "fullScreen" + : undefined, + }, + }), + ArtworkCertificateAuthenticity: reactModule({ + Component: CertificateOfAuthenticity, + options: { + fullBleed: true, + alwaysPresentModally: !unsafe_getFeatureFlag("AREnableNewNavigation"), + modalPresentationStyle: !unsafe_getFeatureFlag("AREnableNewNavigation") + ? "fullScreen" + : undefined, + }, + }), + ArtworkList: reactModule({ + Component: ArtworkListScreen, + options: { + screenOptions: { + headerShown: false, + }, + }, + }), + ArtworkRecommendations: reactModule({ Component: ArtworkRecommendationsScreen }), + Auction: reactModule({ + Component: SaleQueryRenderer, + options: { fullBleed: true }, + Queries: [SaleScreenQuery], + }), + Auctions: reactModule({ + Component: SalesScreen, + options: { + fullBleed: true, + screenOptions: { + headerShown: false, + }, + }, + Queries: [SalesScreenQuery], + }), + AuctionInfo: reactModule({ Component: SaleInfoQueryRenderer }), + AuctionResult: reactModule({ + Component: AuctionResultQueryRenderer, + options: { + hidesBackButton: !unsafe_getFeatureFlag("AREnableNewNavigation"), + }, + }), + AuctionResultsForArtistsYouFollow: reactModule({ + Component: AuctionResultsForArtistsYouFollowQueryRenderer, + Queries: [AuctionResultsForArtistsYouFollowPrefetchQuery], + }), + AuctionResultsForArtistsYouCollect: reactModule({ + Component: AuctionResultsForArtistsYouCollect, + }), + AuctionRegistration: reactModule({ + Component: RegistrationFlow, + options: { + alwaysPresentModally: true, + fullBleed: Platform.OS === "ios" && !unsafe_getFeatureFlag("AREnableNewNavigation"), + screenOptions: { + // Don't allow the screen to be swiped away by mistake + gestureEnabled: false, + headerShown: false, + }, }, - [ArtworkScreenQuery] - ), - ArtworkMedium: reactModule(ArtworkMediumQueryRenderer, { - fullBleed: true, - alwaysPresentModally: !unsafe_getFeatureFlag("AREnableNewNavigation"), - modalPresentationStyle: !unsafe_getFeatureFlag("AREnableNewNavigation") - ? "fullScreen" - : undefined, - }), - ArtworkAttributionClassFAQ: reactModule(ArtworkAttributionClassFAQQueryRenderer, { - fullBleed: true, - alwaysPresentModally: !unsafe_getFeatureFlag("AREnableNewNavigation"), - modalPresentationStyle: !unsafe_getFeatureFlag("AREnableNewNavigation") - ? "fullScreen" - : undefined, - }), - ArtworkCertificateAuthenticity: reactModule(CertificateOfAuthenticity, { - fullBleed: true, - alwaysPresentModally: !unsafe_getFeatureFlag("AREnableNewNavigation"), - modalPresentationStyle: !unsafe_getFeatureFlag("AREnableNewNavigation") - ? "fullScreen" - : undefined, - }), - ArtworkList: reactModule(ArtworkListScreen, { hidesBackButton: true }), - ArtworkRecommendations: reactModule(ArtworkRecommendationsScreen), - Auction: reactModule(SaleQueryRenderer, { fullBleed: true }, [SaleScreenQuery]), - Auctions: reactModule( - SalesScreen, - { - hidesBackButton: true, - fullBleed: true, - }, - [SalesScreenQuery] - ), - AuctionInfo: reactModule(SaleInfoQueryRenderer), - AuctionResult: reactModule(AuctionResultQueryRenderer, { - hidesBackButton: !unsafe_getFeatureFlag("AREnableNewNavigation"), - }), - AuctionResultsForArtistsYouFollow: reactModule( - AuctionResultsForArtistsYouFollowQueryRenderer, - {}, - [AuctionResultsForArtistsYouFollowPrefetchQuery] - ), - AuctionResultsForArtistsYouCollect: reactModule(AuctionResultsForArtistsYouCollect), - AuctionRegistration: reactModule(RegistrationFlow, { - alwaysPresentModally: true, - fullBleed: Platform.OS === "ios" && !unsafe_getFeatureFlag("AREnableNewNavigation"), - hasOwnModalCloseButton: true, - screenOptions: { - // Don't allow the screen to be swiped away by mistake - gestureEnabled: false, - }, - }), - AuctionBidArtwork: reactModule(BidFlow, { - alwaysPresentModally: true, - hasOwnModalCloseButton: true, - fullBleed: !unsafe_getFeatureFlag("AREnableNewNavigation"), - }), - AuctionBuyersPremium: reactModule(AuctionBuyersPremiumQueryRenderer, { - fullBleed: true, - alwaysPresentModally: !unsafe_getFeatureFlag("AREnableNewNavigation"), - modalPresentationStyle: !unsafe_getFeatureFlag("AREnableNewNavigation") - ? "fullScreen" - : undefined, - }), - BottomTabs: reactModule(BottomTabs, { fullBleed: true }), - BrowseSimilarWorks: reactModule(BrowseSimilarWorksQueryRenderer, { - hidesBackButton: true, - hidesBottomTabs: true, - }), - CareerHighlightsBigCardsSwiper: reactModule(CareerHighlightsBigCardsSwiper, { - alwaysPresentModally: !unsafe_getFeatureFlag("AREnableNewNavigation"), - fullBleed: !unsafe_getFeatureFlag("AREnableNewNavigation"), - hidesBackButton: true, - hidesBottomTabs: unsafe_getFeatureFlag("AREnableNewNavigation"), - }), - City: reactModule(CityView, { fullBleed: true, ignoreTabs: true }), - CityFairList: reactModule(CityFairListQueryRenderer, { fullBleed: true }), - CityPicker: reactModule(CityPicker, { fullBleed: true, ignoreTabs: true }), - CitySavedList: reactModule(CitySavedListQueryRenderer), - CitySectionList: reactModule(CitySectionListQueryRenderer), - Collection: reactModule(CollectionScreen, { fullBleed: true, hidesBackButton: true }), - CollectionsByCategory: reactModule(CollectionsByCategory, { - fullBleed: true, - hidesBackButton: true, - }), - ConsignmentInquiry: reactModule(ConsignmentInquiryScreen, { - hidesBottomTabs: !unsafe_getFeatureFlag("AREnableNewNavigation"), - screenOptions: { - gestureEnabled: false, - }, - }), - Conversation: reactModule(Conversation, { - onlyShowInTabName: "inbox", - hidesBackButton: true, - }), - ConversationDetails: reactModule(ConversationDetailsQueryRenderer, { - screenOptions: { - headerTitle: "Details", - }, - }), - DarkModeSettings: reactModule(DarkModeSettings), - DevMenu: reactModule(DevMenu, { - // No need to hide bottom tabs if it's a modal because they will be hidden by default - hidesBottomTabs: !unsafe_getFeatureFlag("AREnableNewNavigation"), - hidesBackButton: !unsafe_getFeatureFlag("AREnableNewNavigation"), - alwaysPresentModally: !!unsafe_getFeatureFlag("AREnableNewNavigation"), - fullBleed: !!unsafe_getFeatureFlag("AREnableNewNavigation"), - screenOptions: { - headerTitle: "Dev Settings", - headerLargeTitle: true, - headerLeft: () => { - return - }, - }, - }), - EditSavedSearchAlert: reactModule(EditSavedSearchAlertQueryRenderer, { - hidesBackButton: true, - hidesBottomTabs: true, - }), - Fair: reactModule(FairScreen, { fullBleed: true, hidesBackButton: true }, [FairScreenQuery]), - FairMoreInfo: reactModule(FairMoreInfoQueryRenderer, { fullBleed: true, hidesBackButton: true }), - FairArticles: reactModule(FairArticlesQueryRenderer), - FairAllFollowedArtists: reactModule(FairAllFollowedArtistsQueryRenderer), - Favorites: reactModule(Favorites, { - fullBleed: true, - hidesBackButton: true, - }), - Feature: reactModule(FeatureQueryRenderer, { fullBleed: true }), - FullArtistSeriesList: reactModule(ArtistSeriesFullArtistSeriesListQueryRenderer), - FullFeaturedArtistList: reactModule(CollectionFullFeaturedArtistListQueryRenderer, { - screenOptions: { - headerTitle: "Featured Artists", - }, - }), - GalleriesForYou: reactModule(GalleriesForYouScreen, { - fullBleed: true, - hidesBackButton: true, - }), - Gene: reactModule(GeneQueryRenderer, { - fullBleed: true, - hidesBackButton: true, - }), - Home: reactModule( - HomeContainer, - { + }), + AuctionBidArtwork: reactModule({ + Component: BidFlow, + options: { + alwaysPresentModally: true, + fullBleed: !unsafe_getFeatureFlag("AREnableNewNavigation"), + screenOptions: { + headerShown: false, + }, + }, + }), + AuctionBuyersPremium: reactModule({ + Component: AuctionBuyersPremiumQueryRenderer, + options: { + fullBleed: true, + alwaysPresentModally: !unsafe_getFeatureFlag("AREnableNewNavigation"), + modalPresentationStyle: !unsafe_getFeatureFlag("AREnableNewNavigation") + ? "fullScreen" + : undefined, + }, + }), + BottomTabs: reactModule({ Component: BottomTabs, options: { fullBleed: true } }), + BrowseSimilarWorks: reactModule({ + Component: BrowseSimilarWorksQueryRenderer, + options: { + hidesBottomTabs: true, + screenOptions: { + headerShown: false, + }, + }, + }), + CareerHighlightsBigCardsSwiper: reactModule({ + Component: CareerHighlightsBigCardsSwiper, + options: { + alwaysPresentModally: !unsafe_getFeatureFlag("AREnableNewNavigation"), + fullBleed: !unsafe_getFeatureFlag("AREnableNewNavigation"), + hidesBottomTabs: unsafe_getFeatureFlag("AREnableNewNavigation"), + screenOptions: { + headerShown: false, + }, + }, + }), + City: reactModule({ Component: CityView, options: { fullBleed: true, ignoreTabs: true } }), + CityFairList: reactModule({ Component: CityFairListQueryRenderer, options: { fullBleed: true } }), + CityPicker: reactModule({ + Component: CityPicker, + options: { fullBleed: true, ignoreTabs: true }, + }), + CitySavedList: reactModule({ Component: CitySavedListQueryRenderer }), + CitySectionList: reactModule({ Component: CitySectionListQueryRenderer }), + Collection: reactModule({ + Component: CollectionScreen, + options: { + fullBleed: true, + screenOptions: { + headerShown: false, + }, + }, + }), + CollectionsByCategory: reactModule({ + Component: CollectionsByCategory, + options: { + fullBleed: true, + screenOptions: { + headerShown: false, + }, + }, + }), + ConsignmentInquiry: reactModule({ + Component: ConsignmentInquiryScreen, + options: { + hidesBottomTabs: !unsafe_getFeatureFlag("AREnableNewNavigation"), + screenOptions: { + gestureEnabled: false, + }, + }, + }), + Conversation: reactModule({ + Component: Conversation, + options: { + onlyShowInTabName: "inbox", + screenOptions: { + headerShown: false, + }, + }, + }), + ConversationDetails: reactModule({ + Component: ConversationDetailsQueryRenderer, + options: { + screenOptions: { + headerTitle: "Details", + }, + }, + }), + DarkModeSettings: reactModule({ Component: DarkModeSettings }), + DevMenu: reactModule({ + Component: DevMenu, + options: { + // No need to hide bottom tabs if it's a modal because they will be hidden by default + hidesBottomTabs: !unsafe_getFeatureFlag("AREnableNewNavigation"), + hidesBackButton: !unsafe_getFeatureFlag("AREnableNewNavigation"), + alwaysPresentModally: !!unsafe_getFeatureFlag("AREnableNewNavigation"), + fullBleed: !!unsafe_getFeatureFlag("AREnableNewNavigation"), + screenOptions: { + headerTitle: "Dev Settings", + headerLargeTitle: true, + headerLeft: () => { + return + }, + }, + }, + }), + EditSavedSearchAlert: reactModule({ + Component: EditSavedSearchAlertQueryRenderer, + options: { + hidesBottomTabs: true, + screenOptions: { + headerShown: false, + }, + }, + }), + Fair: reactModule({ + Component: FairScreen, + options: { + fullBleed: true, + screenOptions: { + headerShown: false, + }, + }, + Queries: [FairScreenQuery], + }), + FairMoreInfo: reactModule({ + Component: FairMoreInfoQueryRenderer, + options: { + fullBleed: true, + screenOptions: { + headerShown: false, + }, + }, + }), + FairArticles: reactModule({ Component: FairArticlesQueryRenderer }), + FairAllFollowedArtists: reactModule({ Component: FairAllFollowedArtistsQueryRenderer }), + Favorites: reactModule({ + Component: Favorites, + options: { + fullBleed: true, + screenOptions: { + headerShown: false, + }, + }, + }), + Feature: reactModule({ Component: FeatureQueryRenderer, options: { fullBleed: true } }), + FullArtistSeriesList: reactModule({ Component: ArtistSeriesFullArtistSeriesListQueryRenderer }), + FullFeaturedArtistList: reactModule({ + Component: CollectionFullFeaturedArtistListQueryRenderer, + options: { + screenOptions: { + headerTitle: "Featured Artists", + }, + }, + }), + GalleriesForYou: reactModule({ + Component: GalleriesForYouScreen, + options: { + fullBleed: true, + screenOptions: { + headerShown: false, + }, + }, + }), + Gene: reactModule({ + Component: GeneQueryRenderer, + options: { + fullBleed: true, + screenOptions: { + headerShown: false, + }, + }, + }), + Home: reactModule({ + Component: HomeContainer, + options: { isRootViewForTabName: "home", - hidesBackButton: true, fullBleed: true, + screenOptions: { + headerShown: false, + }, }, - [homeViewScreenQuery] - ), - HomeView: reactModule(HomeViewScreen, { hidesBackButton: true }), - HomeViewSectionScreen: reactModule(HomeViewSectionScreenQueryRenderer, { - hidesBackButton: true, - fullBleed: true, + Queries: [homeViewScreenQuery], }), - Inbox: reactModule( - InboxQueryRenderer, - { + HomeView: reactModule({ + Component: HomeViewScreen, + options: { + screenOptions: { + headerShown: false, + }, + }, + }), + HomeViewSectionScreen: reactModule({ + Component: HomeViewSectionScreenQueryRenderer, + options: { + fullBleed: true, + screenOptions: { + headerShown: false, + }, + }, + }), + Inbox: reactModule({ + Component: InboxQueryRenderer, + options: { isRootViewForTabName: "inbox", - hidesBackButton: true, - fullBleed: true, - }, - [InboxScreenQuery] - ), - Inquiry: reactModule(Inquiry, { alwaysPresentModally: true, hasOwnModalCloseButton: true }), - LiveAuction: reactModule(LiveAuctionView, { - alwaysPresentModally: true, - hasOwnModalCloseButton: true, - modalPresentationStyle: "fullScreen", - }), - LocalDiscovery: reactModule(CityGuideView, { - fullBleed: true, - screenOptions: unsafe_getFeatureFlag("AREnableNewNavigation") - ? { - headerTransparent: true, - headerLeft: () => { - return ( - { - goBack() - }} - /> - ) - }, - } - : undefined, - }), - MakeOfferModal: reactModule(MakeOfferModalQueryRenderer, { - hasOwnModalCloseButton: true, - }), - MedianSalePriceAtAuction: reactModule(MedianSalePriceAtAuction), - Map: reactModule(MapContainer, { fullBleed: true, ignoreTabs: true }), - MyAccount: reactModule(MyAccountQueryRenderer, { - screenOptions: { - headerTitle: "Account Settings", - }, - }), - MyAccountEditEmail: reactModule(MyAccountEditEmailQueryRenderer, { - hidesBackButton: !unsafe_getFeatureFlag("AREnableNewNavigation"), - screenOptions: { - headerTitle: "Email", - }, - }), - MyAccountEditPriceRange: reactModule(MyAccountEditPriceRangeQueryRenderer, { - hidesBackButton: !unsafe_getFeatureFlag("AREnableNewNavigation"), - screenOptions: { - headerTitle: "Price Range", - }, - }), - MyAccountEditPassword: reactModule(MyAccountEditPassword, { - hidesBackButton: !unsafe_getFeatureFlag("AREnableNewNavigation"), - screenOptions: { - headerTitle: "Password", - }, - }), - MyAccountEditPhone: reactModule(MyAccountEditPhoneQueryRenderer, { - hidesBackButton: !unsafe_getFeatureFlag("AREnableNewNavigation"), - screenOptions: { - headerTitle: "Phone Number", - }, - }), - MyAccountDeleteAccount: reactModule(MyAccountDeleteAccountQueryRenderer), - MyBids: reactModule(MyBidsQueryRenderer), - MyCollection: reactModule(MyCollectionQueryRenderer), - MyCollectionArtwork: reactModule( - MyCollectionArtworkScreen, - { fullBleed: true, hidesBackButton: true }, - [MyCollectionArtworkScreenQuery] - ), - MyCollectionArtworkAdd: reactModule(MyCollectionArtworkAdd, { - hidesBackButton: true, - hidesBottomTabs: !unsafe_getFeatureFlag("AREnableNewNavigation"), - alwaysPresentModally: true, - modalPresentationStyle: "fullScreen", - screenOptions: { - gestureEnabled: false, - }, - }), - MyCollectionArtworkEdit: reactModule(MyCollectionArtworkEditQueryRenderer, { - hidesBackButton: true, - hidesBottomTabs: !unsafe_getFeatureFlag("AREnableNewNavigation"), - alwaysPresentModally: true, - modalPresentationStyle: "fullScreen", - screenOptions: { - gestureEnabled: false, - }, - }), - MyCollectionAddCollectedArtists: reactModule(MyCollectionAddCollectedArtistsScreen, { - hidesBackButton: !unsafe_getFeatureFlag("AREnableNewNavigation"), - hidesBottomTabs: true, - screenOptions: { - headerTitle: "Add Artists You Collect", - gestureEnabled: false, - }, - }), - MyCollectionSellingWithartsyFAQ: reactModule(MyCollectionSellingWithArtsyFAQ), - MyCollectionCollectedArtistsPrivacy: reactModule( - MyCollectionCollectedArtistsPrivacyQueryRenderer, - { - hidesBackButton: true, + fullBleed: true, + screenOptions: { + headerShown: false, + }, + }, + Queries: [InboxScreenQuery], + }), + Inquiry: reactModule({ + Component: Inquiry, + options: { + alwaysPresentModally: true, + screenOptions: { + headerShown: false, + }, + }, + }), + LiveAuction: reactModule({ + Component: LiveAuctionView, + options: { + alwaysPresentModally: true, + modalPresentationStyle: "fullScreen", + screenOptions: { + headerShown: false, + }, + }, + }), + LocalDiscovery: reactModule({ + Component: CityGuideView, + options: { + fullBleed: true, + screenOptions: unsafe_getFeatureFlag("AREnableNewNavigation") + ? { + headerTransparent: true, + headerLeft: () => { + return ( + { + goBack() + }} + /> + ) + }, + } + : undefined, + }, + }), + MakeOfferModal: reactModule({ + Component: MakeOfferModalQueryRenderer, + options: { + screenOptions: { + headerShown: false, + }, + }, + }), + MedianSalePriceAtAuction: reactModule({ Component: MedianSalePriceAtAuction }), + Map: reactModule({ Component: MapContainer, options: { fullBleed: true, ignoreTabs: true } }), + MyAccount: reactModule({ + Component: MyAccountQueryRenderer, + options: { + screenOptions: { + headerTitle: "Account Settings", + }, + }, + }), + MyAccountEditEmail: reactModule({ + Component: MyAccountEditEmailQueryRenderer, + options: { + hidesBackButton: !unsafe_getFeatureFlag("AREnableNewNavigation"), + screenOptions: { + headerTitle: "Email", + }, + }, + }), + MyAccountEditPriceRange: reactModule({ + Component: MyAccountEditPriceRangeQueryRenderer, + options: { + hidesBackButton: !unsafe_getFeatureFlag("AREnableNewNavigation"), + screenOptions: { + headerTitle: "Price Range", + }, + }, + }), + MyAccountEditPassword: reactModule({ + Component: MyAccountEditPassword, + options: { + hidesBackButton: !unsafe_getFeatureFlag("AREnableNewNavigation"), + screenOptions: { + headerTitle: "Password", + }, + }, + }), + MyAccountEditPhone: reactModule({ + Component: MyAccountEditPhoneQueryRenderer, + options: { + hidesBackButton: !unsafe_getFeatureFlag("AREnableNewNavigation"), + screenOptions: { + headerTitle: "Phone Number", + }, + }, + }), + MyAccountDeleteAccount: reactModule({ Component: MyAccountDeleteAccountQueryRenderer }), + MyBids: reactModule({ Component: MyBidsQueryRenderer }), + MyCollection: reactModule({ Component: MyCollectionQueryRenderer }), + MyCollectionArtwork: reactModule({ + Component: MyCollectionArtworkScreen, + options: { + fullBleed: true, + screenOptions: { + headerShown: false, + }, + }, + Queries: [MyCollectionArtworkScreenQuery], + }), + MyCollectionArtworkAdd: reactModule({ + Component: MyCollectionArtworkAdd, + options: { + hidesBottomTabs: !unsafe_getFeatureFlag("AREnableNewNavigation"), + alwaysPresentModally: true, + modalPresentationStyle: "fullScreen", + screenOptions: { + gestureEnabled: false, + headerShown: false, + }, + }, + }), + MyCollectionArtworkEdit: reactModule({ + Component: MyCollectionArtworkEditQueryRenderer, + options: { + hidesBottomTabs: !unsafe_getFeatureFlag("AREnableNewNavigation"), + alwaysPresentModally: true, + modalPresentationStyle: "fullScreen", + screenOptions: { + gestureEnabled: false, + headerShown: false, + }, + }, + }), + MyCollectionAddCollectedArtists: reactModule({ + Component: MyCollectionAddCollectedArtistsScreen, + options: { + hidesBackButton: !unsafe_getFeatureFlag("AREnableNewNavigation"), hidesBottomTabs: true, screenOptions: { + headerTitle: "Add Artists You Collect", gestureEnabled: false, }, - } - ), + }, + }), + MyCollectionSellingWithartsyFAQ: reactModule({ Component: MyCollectionSellingWithArtsyFAQ }), + MyCollectionCollectedArtistsPrivacy: reactModule({ + Component: MyCollectionCollectedArtistsPrivacyQueryRenderer, + options: { + hidesBottomTabs: true, + screenOptions: { + gestureEnabled: false, + headerShown: false, + }, + }, + }), - MyProfile: reactModule( - MyProfile, - { + MyProfile: reactModule({ + Component: MyProfile, + options: { isRootViewForTabName: "profile", fullBleed: true, - hidesBackButton: true, + screenOptions: { + headerShown: false, + }, + }, + Queries: [MyCollectionScreenQuery], + }), + CompleteMyProfile: reactModule({ + Component: CompleteMyProfile, + options: { + fullBleed: true, + hidesBottomTabs: true, + screenOptions: { + headerShown: false, + }, + }, + }), + MyProfileEditForm: reactModule({ + Component: MyProfileEditFormScreen, + options: { + screenOptions: { + headerTitle: "Edit Profile", + }, + }, + }), + MyProfilePayment: reactModule({ + Component: MyProfilePaymentQueryRenderer, + options: { + screenOptions: { + headerTitle: "Payment", + }, + }, + }), + MyProfileSettings: reactModule({ + Component: MyProfileSettings, + options: { + screenOptions: { + headerTitle: "Account", + }, + }, + }), + MySellingProfile: reactModule({ Component: View }), + NewWorksForYou: reactModule({ + Component: NewWorksForYouQueryRenderer, + options: { + hidesBottomTabs: true, + fullBleed: true, + screenOptions: { + headerShown: false, + }, + }, + }), + MyProfilePaymentNewCreditCard: reactModule({ + Component: MyProfilePaymentNewCreditCard, + options: { + screenOptions: { + headerTitle: "Add new card", + }, + }, + }), + MyProfilePushNotifications: reactModule({ + Component: MyProfilePushNotificationsQueryRenderer, + options: { + screenOptions: { + headerTitle: "Push Notifications", + }, + }, + }), + NewWorksFromGalleriesYouFollow: reactModule({ + Component: NewWorksFromGalleriesYouFollowScreen, + options: { + fullBleed: true, + screenOptions: { + headerShown: false, + }, + }, + }), + News: reactModule({ + Component: NewsScreen, + options: { + fullBleed: true, + screenOptions: { + headerShown: false, + }, + }, + Queries: [NewsScreenQuery], + }), + OrderHistory: reactModule({ + Component: OrderHistoryQueryRender, + options: { + screenOptions: { + headerTitle: "Order History", + }, + }, + }), + OrderDetails: reactModule({ + Component: OrderDetailsQueryRender, + options: { + screenOptions: { + headerTitle: "Order Details", + }, + }, + }), + Partner: reactModule({ + Component: PartnerQueryRenderer, + options: { + fullBleed: true, + }, + }), + PartnerLocations: reactModule({ Component: PartnerLocations }), + PartnerOfferContainer: reactModule({ + Component: PartnerOfferContainer, + options: { + hidesBottomTabs: true, + screenOptions: { + headerShown: false, + }, + }, + }), + PriceDatabase: reactModule({ + Component: PriceDatabase, + options: { + screenOptions: { + headerShown: false, + }, + }, + }), + PrivacyRequest: reactModule({ + Component: PrivacyRequest, + options: { + screenOptions: { + headerTitle: "Personal Data Request", + }, + }, + }), + PurchaseModal: reactModule({ + Component: PurchaseModalQueryRenderer, + options: { + screenOptions: { + headerShown: false, + }, + }, + }), + ModalWebView: reactModule({ + Component: ArtsyWebViewPage, + options: { + alwaysPresentModally: true, + modalPresentationStyle: !unsafe_getFeatureFlag("AREnableNewNavigation") + ? "fullScreen" + : undefined, + screenOptions: { + gestureEnabled: false, + headerShown: false, + }, + }, + }), + ReactWebView: reactModule({ + Component: ArtsyWebViewPage, + options: { + fullBleed: !unsafe_getFeatureFlag("AREnableNewNavigation"), + screenOptions: { + headerShown: false, + }, + }, + }), + RequestForPriceEstimateScreen: reactModule({ Component: RequestForPriceEstimateScreen }), + RequestForPriceEstimateConfirmationScreen: reactModule({ + Component: RequestForPriceEstimateConfirmationScreen, + options: { + screenOptions: { + headerShown: false, + }, + }, + }), + RecentlyViewed: reactModule({ + Component: RecentlyViewedScreen, + options: { + fullBleed: true, + screenOptions: { + headerShown: false, + }, }, - [MyCollectionScreenQuery] - ), - CompleteMyProfile: reactModule(CompleteMyProfile, { - fullBleed: true, - hidesBackButton: true, - hidesBottomTabs: true, + Queries: [RecentlyViewedScreenQuery], }), - MyProfileEditForm: reactModule(MyProfileEditFormScreen, { - screenOptions: { - headerTitle: "Edit Profile", + RecommendedAuctionLots: reactModule({ + Component: RecommendedAuctionLotsQueryRenderer, + options: { + hidesBottomTabs: true, + fullBleed: true, + screenOptions: { + headerShown: false, + }, }, }), - MyProfilePayment: reactModule(MyProfilePaymentQueryRenderer, { - screenOptions: { - headerTitle: "Payment", + Sell: reactModule({ + Component: SellWithArtsy, + options: { + isRootViewForTabName: "sell", + fullBleed: true, + screenOptions: { + headerShown: false, + }, }, + Queries: [SellWithArtsyHomeScreenQuery], }), - MyProfileSettings: reactModule(MyProfileSettings, { - screenOptions: { - headerTitle: "Account", + SellNotRootTabView: reactModule({ Component: SellWithArtsy }), + SavedArtworks: reactModule({ + Component: SavedArtworks, + options: { + fullBleed: true, + screenOptions: { + headerShown: false, + }, }, }), - MySellingProfile: reactModule(View), - NewWorksForYou: reactModule(NewWorksForYouQueryRenderer, { - hidesBottomTabs: true, - hidesBackButton: true, - fullBleed: true, + SavedSearchAlertsList: reactModule({ + Component: SavedSearchAlertsListQueryRenderer, + options: { + fullBleed: true, + screenOptions: { + headerShown: false, + }, + }, }), - MyProfilePaymentNewCreditCard: reactModule(MyProfilePaymentNewCreditCard, { - screenOptions: { - headerTitle: "Add new card", + Search: reactModule({ + Component: SearchScreen, + options: { + isRootViewForTabName: "search", + fullBleed: true, + screenOptions: { + headerShown: false, + }, }, + Queries: [SearchScreenQuery], }), - MyProfilePushNotifications: reactModule(MyProfilePushNotificationsQueryRenderer, { - screenOptions: { - headerTitle: "Push Notifications", + Show: reactModule({ Component: ShowQueryRenderer, options: { fullBleed: true } }), + ShowMoreInfo: reactModule({ Component: ShowMoreInfoQueryRenderer }), + SimilarToRecentlyViewed: reactModule({ + Component: SimilarToRecentlyViewedScreen, + options: { + fullBleed: true, + screenOptions: { + headerShown: false, + }, }, }), - NewWorksFromGalleriesYouFollow: reactModule(NewWorksFromGalleriesYouFollowScreen, { - hidesBackButton: true, - fullBleed: true, - }), - News: reactModule( - NewsScreen, - { - fullBleed: true, - hidesBackButton: true, - }, - [NewsScreenQuery] - ), - OrderHistory: reactModule(OrderHistoryQueryRender, { - screenOptions: { - headerTitle: "Order History", + SubmitArtwork: reactModule({ + Component: SubmitArtworkForm, + options: { + alwaysPresentModally: true, + modalPresentationStyle: !unsafe_getFeatureFlag("AREnableNewNavigation") + ? "fullScreen" + : undefined, + screenOptions: { + gestureEnabled: false, + headerShown: false, + }, }, }), - OrderDetails: reactModule(OrderDetailsQueryRender, { - screenOptions: { - headerTitle: "Order Details", - }, - }), - Partner: reactModule(PartnerQueryRenderer, { - fullBleed: true, - hidesBackButton: true, - }), - PartnerLocations: reactModule(PartnerLocations), - PartnerOfferContainer: reactModule(PartnerOfferContainer, { - hidesBottomTabs: true, - hidesBackButton: true, - }), - PriceDatabase: reactModule(PriceDatabase, { hidesBackButton: true }), - PrivacyRequest: reactModule(PrivacyRequest, { - screenOptions: { - headerTitle: "Personal Data Request", - }, - }), - PurchaseModal: reactModule(PurchaseModalQueryRenderer, { - hasOwnModalCloseButton: true, - }), - ModalWebView: reactModule(ArtsyWebViewPage, { - hasOwnModalCloseButton: true, - hidesBackButton: true, - alwaysPresentModally: true, - modalPresentationStyle: !unsafe_getFeatureFlag("AREnableNewNavigation") - ? "fullScreen" - : undefined, - screenOptions: { - gestureEnabled: false, - }, - }), - ReactWebView: reactModule(ArtsyWebViewPage, { - fullBleed: !unsafe_getFeatureFlag("AREnableNewNavigation"), - hasOwnModalCloseButton: true, - hidesBackButton: true, - }), - RequestForPriceEstimateScreen: reactModule(RequestForPriceEstimateScreen), - RequestForPriceEstimateConfirmationScreen: reactModule( - RequestForPriceEstimateConfirmationScreen, - { hidesBackButton: true } - ), - RecentlyViewed: reactModule( - RecentlyViewedScreen, - { - hidesBackButton: true, - fullBleed: true, - }, - [RecentlyViewedScreenQuery] - ), - RecommendedAuctionLots: reactModule(RecommendedAuctionLotsQueryRenderer, { - hidesBottomTabs: true, - hidesBackButton: true, - fullBleed: true, - }), - Sell: reactModule( - SellWithArtsy, - { isRootViewForTabName: "sell", fullBleed: true, hidesBackButton: true }, - [SellWithArtsyHomeScreenQuery] - ), - SellNotRootTabView: reactModule(SellWithArtsy), - SavedArtworks: reactModule(SavedArtworks, { - fullBleed: true, - hidesBackButton: true, - }), - SavedSearchAlertsList: reactModule(SavedSearchAlertsListQueryRenderer, { - fullBleed: true, - hidesBackButton: true, - }), - Search: reactModule( - SearchScreen, - { isRootViewForTabName: "search", hidesBackButton: true, fullBleed: true }, - [SearchScreenQuery] - ), - Show: reactModule(ShowQueryRenderer, { fullBleed: true }), - ShowMoreInfo: reactModule(ShowMoreInfoQueryRenderer), - SimilarToRecentlyViewed: reactModule(SimilarToRecentlyViewedScreen, { - hidesBackButton: true, - fullBleed: true, - }), - SubmitArtwork: reactModule(SubmitArtworkForm, { - hidesBackButton: true, - alwaysPresentModally: true, - modalPresentationStyle: !unsafe_getFeatureFlag("AREnableNewNavigation") - ? "fullScreen" - : undefined, - screenOptions: { - gestureEnabled: false, - }, - }), - SubmitArtworkEdit: reactModule(SubmitArtworkFormEditContainer, { - hidesBackButton: true, - alwaysPresentModally: true, - hidesBottomTabs: true, - screenOptions: { - gestureEnabled: false, - }, - }), - Tag: reactModule(TagQueryRenderer, { hidesBackButton: true, fullBleed: true }), - UnlistedArtworksFAQScreen: reactModule(UnlistedArtworksFAQScreen), - VanityURLEntity: reactModule(VanityURLEntityRenderer, { fullBleed: true }), - ViewingRoom: reactModule(ViewingRoomQueryRenderer, { fullBleed: true }, [ViewingRoomScreenQuery]), - ViewingRoomArtwork: reactModule(ViewingRoomArtworkScreen), - ViewingRoomArtworks: reactModule(ViewingRoomArtworksQueryRenderer), - ViewingRooms: reactModule(ViewingRoomsListScreen, {}, [viewingRoomsListScreenQuery]), - WorksForYou: reactModule(WorksForYouQueryRenderer, {}, [WorksForYouScreenQuery]), + SubmitArtworkEdit: reactModule({ + Component: SubmitArtworkFormEditContainer, + options: { + alwaysPresentModally: true, + hidesBottomTabs: true, + screenOptions: { + gestureEnabled: false, + headerShown: false, + }, + }, + }), + Tag: reactModule({ + Component: TagQueryRenderer, + options: { + fullBleed: true, + screenOptions: { + headerShown: false, + }, + }, + }), + UnlistedArtworksFAQScreen: reactModule({ Component: UnlistedArtworksFAQScreen }), + VanityURLEntity: reactModule({ + Component: VanityURLEntityRenderer, + options: { fullBleed: true }, + }), + ViewingRoom: reactModule({ + Component: ViewingRoomQueryRenderer, + options: { fullBleed: true }, + Queries: [ViewingRoomScreenQuery], + }), + ViewingRoomArtwork: reactModule({ Component: ViewingRoomArtworkScreen }), + ViewingRoomArtworks: reactModule({ Component: ViewingRoomArtworksQueryRenderer }), + ViewingRooms: reactModule({ + Component: ViewingRoomsListScreen, + Queries: [viewingRoomsListScreenQuery], + }), + WorksForYou: reactModule({ + Component: WorksForYouQueryRenderer, + Queries: [WorksForYouScreenQuery], + }), }) for (const moduleName of Object.keys(modules)) { diff --git a/src/app/Navigation/AuthenticatedRoutes/StackNavigator.tsx b/src/app/Navigation/AuthenticatedRoutes/StackNavigator.tsx index a8c646d1381..8e78b539999 100644 --- a/src/app/Navigation/AuthenticatedRoutes/StackNavigator.tsx +++ b/src/app/Navigation/AuthenticatedRoutes/StackNavigator.tsx @@ -71,6 +71,7 @@ export const registerScreen: React.FC = ({ name, modu const isFullBleed = module.options.fullBleed ?? // when no header is visible, we want to make sure we are bound by the insets + module.options.screenOptions?.headerShown ?? isHeaderShown(module) const hidesBottomTabs = module.options.hidesBottomTabs || isModalScreen(module) diff --git a/src/app/Navigation/Navigation.tsx b/src/app/Navigation/Navigation.tsx index 29678f89611..2bf4d5d44ca 100644 --- a/src/app/Navigation/Navigation.tsx +++ b/src/app/Navigation/Navigation.tsx @@ -8,7 +8,6 @@ import { AuthenticatedRoutes, AuthenticatedRoutesParams, } from "app/Navigation/AuthenticatedRoutes/Tabs" -import { UnauthenticatedRoutesParams } from "app/Navigation/UnauthenticatedRoutes" import { OnboardingWelcomeScreens } from "app/Scenes/Onboarding/Onboarding" import { GlobalStore } from "app/store/GlobalStore" import { routingInstrumentation } from "app/system/errorReporting/setupSentry" @@ -23,7 +22,7 @@ import SiftReactNative from "sift-react-native" export const internal_navigationRef = { current: null as NavigationContainerRef | null } -export type NavigationRoutesParams = UnauthenticatedRoutesParams & AuthenticatedRoutesParams +export type NavigationRoutesParams = AuthenticatedRoutesParams export const MainStackNavigator = createNativeStackNavigator() diff --git a/src/app/Navigation/UnauthenticatedRoutes.tsx b/src/app/Navigation/UnauthenticatedRoutes.tsx deleted file mode 100644 index bdd5d4d2147..00000000000 --- a/src/app/Navigation/UnauthenticatedRoutes.tsx +++ /dev/null @@ -1,22 +0,0 @@ -import { createNativeStackNavigator } from "@react-navigation/native-stack" -import { MainStackNavigator } from "app/Navigation/Navigation" -import { LoginScreen } from "app/Navigation/_TO_BE_DELETED_Screens/LoginScreen" -import { SignUpScreen } from "app/Navigation/_TO_BE_DELETED_Screens/SignUpScreen" - -export type UnauthenticatedRoutesParams = { - Login: undefined - SignUp: undefined -} - -const UnauthenticatedStack = createNativeStackNavigator() - -export const UnauthenticatedRoutes = () => { - return ( - - - - - - - ) -} diff --git a/src/app/Navigation/_TO_BE_DELETED_Screens/LoginScreen.tsx b/src/app/Navigation/_TO_BE_DELETED_Screens/LoginScreen.tsx deleted file mode 100644 index b162a11e401..00000000000 --- a/src/app/Navigation/_TO_BE_DELETED_Screens/LoginScreen.tsx +++ /dev/null @@ -1,23 +0,0 @@ -import { Button, Flex, Spacer, Text } from "@artsy/palette-mobile" -import { NavigationProp, useNavigation } from "@react-navigation/native" -import { UnauthenticatedRoutesParams } from "app/Navigation/UnauthenticatedRoutes" - -export const LoginScreen: React.FC = () => { - const navigation = useNavigation>() - - return ( - - Login - - - - - - ) -} diff --git a/src/app/Navigation/_TO_BE_DELETED_Screens/SignUpScreen.tsx b/src/app/Navigation/_TO_BE_DELETED_Screens/SignUpScreen.tsx deleted file mode 100644 index 2862aa6d4fd..00000000000 --- a/src/app/Navigation/_TO_BE_DELETED_Screens/SignUpScreen.tsx +++ /dev/null @@ -1,22 +0,0 @@ -import { Button, Flex, Spacer, Text } from "@artsy/palette-mobile" -import { NavigationProp, useNavigation } from "@react-navigation/native" -import { UnauthenticatedRoutesParams } from "app/Navigation/UnauthenticatedRoutes" - -export const SignUpScreen: React.FC = () => { - const navigation = useNavigation>() - return ( - - Sign Up - - - - - - ) -} diff --git a/src/app/Scenes/HomeView/Sections/HomeViewSectionTasks.tsx b/src/app/Scenes/HomeView/Sections/HomeViewSectionTasks.tsx index 1f5d11064ef..1d5408279e5 100644 --- a/src/app/Scenes/HomeView/Sections/HomeViewSectionTasks.tsx +++ b/src/app/Scenes/HomeView/Sections/HomeViewSectionTasks.tsx @@ -142,7 +142,7 @@ const HomeViewSectionTasksPlaceholder: React.FC = (flexProps) => { } const homeViewSectionTasksQuery = graphql` - query HomeViewSectionTasksQuery($id: String!) @cacheable { + query HomeViewSectionTasksQuery($id: String!) { homeView { section(id: $id) { ...HomeViewSectionTasks_section diff --git a/src/app/routes.ts b/src/app/routes.ts index 63374dfb7bf..ff99dffdc3c 100644 --- a/src/app/routes.ts +++ b/src/app/routes.ts @@ -1,3 +1,4 @@ +import { parse } from "url" import { AppModule } from "app/AppRegistry" import { ArtsyWebViewConfig } from "app/Components/ArtsyWebView" import { __unsafe_mainModalStackRef } from "app/NativeModules/ARScreenPresenterModule" @@ -7,7 +8,6 @@ import { compact } from "lodash" import { parse as parseQueryString } from "query-string" import { Platform } from "react-native" import { GraphQLTaggedNode } from "relay-runtime" -import { parse } from "url" export function matchRoute( url: string diff --git a/src/app/store/config/features.ts b/src/app/store/config/features.ts index 9614d6798cc..0152adb6fc8 100644 --- a/src/app/store/config/features.ts +++ b/src/app/store/config/features.ts @@ -274,7 +274,7 @@ export const features = { }, AREnableNewSaveAndFollowOnArtworkCard: { description: "Redesign Save CTA and Add Follow CTA on Artwork Grid/Rail", - readyForRelease: false, + readyForRelease: true, showInDevMenu: true, echoFlagKey: "AREnableNewSaveAndFollowOnArtworkCard", }, diff --git a/src/app/system/navigation/navigate.tests.tsx b/src/app/system/navigation/navigate.tests.tsx index 745783d300d..8f8fc431118 100644 --- a/src/app/system/navigation/navigate.tests.tsx +++ b/src/app/system/navigation/navigate.tests.tsx @@ -60,7 +60,6 @@ describe(navigate, () => { [ "home", { - "hidesBackButton": true, "hidesBottomTabs": true, "moduleName": "Artwork", "props": { @@ -68,6 +67,9 @@ describe(navigate, () => { }, "replaceActiveModal": false, "replaceActiveScreen": false, + "screenOptions": { + "headerShown": false, + }, "type": "react", }, ] @@ -83,13 +85,15 @@ describe(navigate, () => { "home", { "fullBleed": true, - "hidesBackButton": true, "moduleName": "Artist", "props": { "artistID": "banksy", }, "replaceActiveModal": false, "replaceActiveScreen": false, + "screenOptions": { + "headerShown": false, + }, "type": "react", }, ] @@ -137,7 +141,6 @@ describe(navigate, () => { "home", { "fullBleed": true, - "hidesBackButton": true, "moduleName": "Artist", "props": { "artistID": "banksy", @@ -145,6 +148,9 @@ describe(navigate, () => { }, "replaceActiveModal": false, "replaceActiveScreen": false, + "screenOptions": { + "headerShown": false, + }, "type": "react", }, ] @@ -171,13 +177,15 @@ describe(navigate, () => { "home", { "fullBleed": true, - "hidesBackButton": true, "moduleName": "Artist", "props": { "artistID": "kaws", }, "replaceActiveModal": false, "replaceActiveScreen": false, + "screenOptions": { + "headerShown": false, + }, "type": "react", }, ] @@ -194,7 +202,6 @@ describe(navigate, () => { [ { "alwaysPresentModally": true, - "hasOwnModalCloseButton": true, "modalPresentationStyle": "fullScreen", "moduleName": "LiveAuction", "props": { @@ -202,6 +209,9 @@ describe(navigate, () => { }, "replaceActiveModal": false, "replaceActiveScreen": false, + "screenOptions": { + "headerShown": false, + }, "type": "react", }, ] @@ -246,7 +256,6 @@ describe(navigate, () => { [ "inbox", { - "hidesBackButton": true, "moduleName": "Conversation", "onlyShowInTabName": "inbox", "props": { @@ -254,6 +263,9 @@ describe(navigate, () => { }, "replaceActiveModal": false, "replaceActiveScreen": false, + "screenOptions": { + "headerShown": false, + }, "type": "react", }, ] @@ -277,11 +289,13 @@ describe(navigate, () => { "profile", { "fullBleed": true, - "hidesBackButton": true, "moduleName": "SavedSearchAlertsList", "props": {}, "replaceActiveModal": false, "replaceActiveScreen": false, + "screenOptions": { + "headerShown": false, + }, "type": "react", }, ]