-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #11 from fidisys/feature/redux-saga
Feature/redux saga
- Loading branch information
Showing
45 changed files
with
2,188 additions
and
128 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
/** | ||
* Sample React Native App | ||
* https://github.com/facebook/react-native | ||
* | ||
* @format | ||
* @flow | ||
*/ | ||
|
||
import React from 'react'; | ||
import store from './store/configureStore'; | ||
import { Provider } from 'react-redux'; | ||
|
||
|
||
import { Navigation } from './navigation'; | ||
import NavigationService from './utils/navigationService'; | ||
|
||
const App = () => { | ||
return ( | ||
|
||
<Provider store={store}> | ||
<Navigation | ||
ref={navigatorRef => { | ||
NavigationService.setTopLevelNavigator(navigatorRef); | ||
}} | ||
/> | ||
</Provider> | ||
); | ||
}; | ||
|
||
|
||
export default App; |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
import React from 'react'; | ||
import { View, TouchableOpacity, Text } from 'react-native'; | ||
|
||
export const Button = ({ onClick, style, children }) => { | ||
return ( | ||
<TouchableOpacity | ||
onPress={onClick} | ||
activeOpacity={0.7} | ||
style={[{ | ||
padding: 6, | ||
minHeight: 20, | ||
borderRadius: 3, | ||
flexDirection: 'column', | ||
justifyContent: 'center', | ||
alignItems: 'center', | ||
shadowColor: 'rgba(0,0,0, .4)', // IOS | ||
shadowOffset: { height: 3, width: 2 }, // IOS | ||
shadowOpacity: 1, // IOS | ||
shadowRadius: 1, //IOS | ||
backgroundColor: '#fff', | ||
elevation: 3, // Android | ||
}, style]}> | ||
{children} | ||
</TouchableOpacity> | ||
) | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
import React from 'react'; | ||
import { View,SafeAreaView } from 'react-native'; | ||
import {GlobalStyle} from '../theme/global'; | ||
|
||
|
||
export const Container = ({style,children}) => { | ||
return ( | ||
<SafeAreaView style={{flex: 1}}> | ||
|
||
<View style={[style,GlobalStyle.mainContainer]}> | ||
{children} | ||
</View> | ||
</SafeAreaView> | ||
) | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
import React from 'react'; | ||
import { View, } from 'react-native'; | ||
import { KeyboardAwareScrollView } from 'react-native-keyboard-aware-scroll-view' | ||
|
||
|
||
export const Content = ({style,children}) => { | ||
return ( | ||
<KeyboardAwareScrollView | ||
automaticallyAdjustContentInsets={false} | ||
style={{flex: 1}} | ||
showsVerticalScrollIndicator | ||
contentContainerStyle={[{ | ||
padding: 15, | ||
flexDirection: 'column' | ||
},style]}> | ||
{children} | ||
</KeyboardAwareScrollView> | ||
|
||
) | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
import React from 'react'; | ||
import { View, Text } from 'react-native'; | ||
|
||
export const Footer = ({ style, children }) => { | ||
return ( | ||
<View | ||
style={[{ | ||
minHeight: 48, | ||
position: 'absolute', | ||
bottom: 0, | ||
borderTopColor: 'gray', | ||
borderTopWidth: 1, | ||
paddingHorizontal: 10, | ||
width: '100%', | ||
flexDirection: 'row', | ||
justifyContent: 'center', | ||
alignItems: 'center', | ||
backgroundColor: 'transparent' | ||
}, style]}> | ||
{children} | ||
</View> | ||
) | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,59 @@ | ||
import React from 'react'; | ||
import { View,StatusBar } from 'react-native'; | ||
import { BarStyle } from '../theme/global'; | ||
|
||
export const Header = ({style,statusbarColor,barStyle = BarStyle ,children}) => { | ||
console.log(children) | ||
return ( | ||
<View style={[{ | ||
height: 48, | ||
paddingHorizontal: 10, | ||
width: '100%', | ||
flexDirection: 'row', | ||
justifyContent: 'space-between', | ||
alignItems: 'center', | ||
|
||
backgroundColor: '#5297ff' | ||
},style]}> | ||
<StatusBar backgroundColor={statusbarColor} barStyle={barStyle}/> | ||
{children} | ||
</View> | ||
|
||
) | ||
} | ||
|
||
export const HeaderLeft = ({style,children}) => { | ||
return ( | ||
<View style={[{ | ||
flexDirection: 'row', | ||
minWidth: '15%', | ||
justifyContent: 'flex-start', | ||
alignItems: 'center' | ||
},style]}> | ||
{children} | ||
</View> | ||
) | ||
} | ||
export const HeaderBody = ({style,children}) => { | ||
return ( | ||
<View style={[{ | ||
flexDirection:'column', | ||
justifyContent: 'center', | ||
alignItems:'center' | ||
},style]}> | ||
{children} | ||
</View> | ||
) | ||
} | ||
export const HeaderRight = ({style,children}) => { | ||
return ( | ||
<View style={[{ | ||
flexDirection: 'row', | ||
minWidth: '15%', | ||
justifyContent: 'flex-end', | ||
alignItems: 'center' | ||
},style]}> | ||
{children} | ||
</View> | ||
) | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
import React from 'react'; | ||
import { TouchableOpacity } from 'react-native'; | ||
|
||
|
||
export const IconButton = ({style,buttonEvent,children}) => { | ||
return ( | ||
<TouchableOpacity onPress={buttonEvent} | ||
style={{ | ||
minWidth: 30, | ||
minHeight: 30, | ||
flexDirection: 'column', | ||
justifyContent: 'center', | ||
alignItems: 'center' | ||
}}> | ||
{children} | ||
</TouchableOpacity> | ||
) | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
import { Container } from './container'; | ||
import { Header,HeaderBody,HeaderRight,HeaderLeft } from './header'; | ||
import { Content } from './content'; | ||
import { IconButton } from './iconButton'; | ||
import { Button } from './button'; | ||
import { Footer } from './footer'; | ||
export { | ||
Container, | ||
Header, | ||
HeaderBody, | ||
HeaderRight, | ||
HeaderLeft, | ||
Content, | ||
Button, | ||
Footer, | ||
IconButton | ||
} |
Oops, something went wrong.