Skip to content

Commit

Permalink
titles that use translate service moved
Browse files Browse the repository at this point in the history
  • Loading branch information
kanzitelli committed Oct 20, 2022
1 parent 0b76aa6 commit 60522e9
Showing 1 changed file with 14 additions and 16 deletions.
30 changes: 14 additions & 16 deletions src/screens/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -4,23 +4,22 @@ import {gestureHandlerRootHOC as withGestureHandler} from 'react-native-gesture-
import {Main} from './main';
import {Settings} from './settings';

import {withServices} from '../services';
import {withStores} from '../stores';
import {
withBottomTab,
withRightButtons,
withTitle,
} from '../services/navigation/options';
import {withBottomTab, withRightButtons} from '../services/navigation/options';
import {Sample} from './_screen-sample';
import {Playground} from './playground';
import {withAppearance} from '../utils/hooks';
import {withSS} from '../utils/providers';

export const screens = generateRNNScreens(
{
Main: {
component: Main,
options: {
topBar: {
...withTitle('Main'),
// title is set in services/navigation/index.ts
background: {
color: 'red',
},
...withRightButtons('inc', 'dec'),
},
...withBottomTab('Main', 'home'),
Expand All @@ -29,18 +28,14 @@ export const screens = generateRNNScreens(
Playground: {
component: Playground,
options: {
topBar: {
...withTitle('Playground'),
},
topBar: {title: {text: 'Playground'}},
...withBottomTab('Playground', 'construct'),
},
},
Settings: {
component: Settings,
options: {
topBar: {
...withTitle('Settings'),
},
topBar: {title: {text: 'Settings'}},
...withBottomTab('Settings', 'settings'),
},
},
Expand All @@ -49,10 +44,13 @@ export const screens = generateRNNScreens(
component: Sample,
options: {
topBar: {
...withTitle('Sample'),
title: {text: 'Sample'},
background: {
color: 'yellow',
},
},
},
},
},
[withGestureHandler, withStores, withServices],
[withGestureHandler, withSS, withAppearance],
);

0 comments on commit 60522e9

Please sign in to comment.