Skip to content
This repository was archived by the owner on Feb 23, 2021. It is now read-only.
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions src/component/background.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import React from 'react';
import { View, StyleSheet, ImageBackground, ViewPropTypes } from 'react-native';
import { View, StyleSheet, ImageBackground } from 'react-native';
import PropTypes from 'prop-types';

//
Expand Down Expand Up @@ -30,7 +30,7 @@ Background.propTypes = {
image: PropTypes.string,
color: PropTypes.string,
children: PropTypes.node,
style: ViewPropTypes.style,
style: View.propTypes.style,
};

//
Expand Down Expand Up @@ -66,7 +66,7 @@ SplitBackground.propTypes = {
color: PropTypes.string,
bottom: PropTypes.string,
children: PropTypes.node,
style: ViewPropTypes.style,
style: View.propTypes.style,
};

export default Background;
25 changes: 12 additions & 13 deletions src/component/button.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,7 @@ import React from 'react';
import {
View,
TouchableOpacity,
ViewPropTypes,
TextPropTypes,
Text as RNText,
StyleSheet,
} from 'react-native';
import PropTypes from 'prop-types';
Expand Down Expand Up @@ -38,7 +37,7 @@ Button.propTypes = {
onPress: PropTypes.func.isRequired,
disabled: PropTypes.bool,
children: PropTypes.node,
style: ViewPropTypes.style,
style: View.propTypes.style,
};

//
Expand All @@ -58,7 +57,7 @@ export const ButtonText = ({ children, style }) => (

ButtonText.propTypes = {
children: PropTypes.string.isRequired,
style: TextPropTypes.style,
style: RNText.propTypes.style,
};

//
Expand Down Expand Up @@ -98,7 +97,7 @@ GlasButton.propTypes = {
onPress: PropTypes.func.isRequired,
disabled: PropTypes.bool,
children: PropTypes.string.isRequired,
style: ViewPropTypes.style,
style: View.propTypes.style,
};

//
Expand Down Expand Up @@ -134,7 +133,7 @@ PillButton.propTypes = {
onPress: PropTypes.func.isRequired,
disabled: PropTypes.bool,
children: PropTypes.string.isRequired,
style: ViewPropTypes.style,
style: View.propTypes.style,
};

//
Expand Down Expand Up @@ -209,7 +208,7 @@ SmallButton.propTypes = {
border: PropTypes.bool,
alert: PropTypes.string,
children: PropTypes.node,
style: ViewPropTypes.style,
style: View.propTypes.style,
};

//
Expand Down Expand Up @@ -255,7 +254,7 @@ SmallPillButton.propTypes = {
text: PropTypes.string,
onPress: PropTypes.func.isRequired,
disabled: PropTypes.bool,
style: ViewPropTypes.style,
style: View.propTypes.style,
};

//
Expand All @@ -278,7 +277,7 @@ export const BackButton = ({ onPress, disabled, style }) => (
BackButton.propTypes = {
onPress: PropTypes.func,
disabled: PropTypes.bool,
style: ViewPropTypes.style,
style: View.propTypes.style,
};

//
Expand All @@ -301,7 +300,7 @@ export const CancelButton = ({ onPress, disabled, style }) => (
CancelButton.propTypes = {
onPress: PropTypes.func,
disabled: PropTypes.bool,
style: ViewPropTypes.style,
style: View.propTypes.style,
};

//
Expand Down Expand Up @@ -339,7 +338,7 @@ export const QrButton = ({ onPress, disabled, style, children }) => (
QrButton.propTypes = {
onPress: PropTypes.func.isRequired,
disabled: PropTypes.bool,
style: ViewPropTypes.style,
style: View.propTypes.style,
children: PropTypes.string,
};

Expand Down Expand Up @@ -368,7 +367,7 @@ export const DownButton = ({ onPress, disabled, style, children }) => (
DownButton.propTypes = {
onPress: PropTypes.func,
disabled: PropTypes.bool,
style: ViewPropTypes.style,
style: View.propTypes.style,
children: PropTypes.string,
};

Expand Down Expand Up @@ -419,7 +418,7 @@ CopyButton.propTypes = {
onPress: PropTypes.func,
icon: PropTypes.string,
children: PropTypes.string,
style: ViewPropTypes.style,
style: View.propTypes.style,
};

//
Expand Down
4 changes: 2 additions & 2 deletions src/component/card.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import React from 'react';
import { View, ViewPropTypes, StyleSheet } from 'react-native';
import { View, StyleSheet } from 'react-native';
import PropTypes from 'prop-types';
import { color } from './style';

Expand All @@ -22,7 +22,7 @@ const Card = ({ children, style }) => (

Card.propTypes = {
children: PropTypes.node,
style: ViewPropTypes.style,
style: View.propTypes.style,
};

export default Card;
4 changes: 2 additions & 2 deletions src/component/container.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import React from 'react';
import { View, ViewPropTypes, StyleSheet } from 'react-native';
import { View, StyleSheet } from 'react-native';
import PropTypes from 'prop-types';

const styles = StyleSheet.create({
Expand All @@ -15,7 +15,7 @@ const Container = ({ children, style }) => (

Container.propTypes = {
children: PropTypes.node,
style: ViewPropTypes.style,
style: View.propTypes.style,
};

export default Container;
10 changes: 5 additions & 5 deletions src/component/field.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import React from 'react';
import { TextPropTypes, ViewPropTypes, StyleSheet, View } from 'react-native';
import { Text as RNText, StyleSheet, View } from 'react-native';
import PropTypes from 'prop-types';
import Text from './text';
import { TextInput, HorizontalExpandingTextInput } from './input';
Expand Down Expand Up @@ -29,7 +29,7 @@ export const AmountInputField = ({ style, ...props }) => (
);

AmountInputField.propTypes = {
style: TextPropTypes.style,
style: RNText.propTypes.style,
};

//
Expand All @@ -50,7 +50,7 @@ export const InputField = ({ style, ...props }) => (

InputField.propTypes = {
children: PropTypes.string,
style: TextPropTypes.style,
style: RNText.propTypes.style,
};

//
Expand Down Expand Up @@ -93,7 +93,7 @@ export const NamedField = ({ name, children, style }) => (
NamedField.propTypes = {
name: PropTypes.string,
children: PropTypes.oneOfType([PropTypes.string, PropTypes.array]),
style: ViewPropTypes.style,
style: View.propTypes.style,
};

//
Expand Down Expand Up @@ -130,5 +130,5 @@ export const DetailField = ({ name, children, style }) => (
DetailField.propTypes = {
name: PropTypes.string,
children: PropTypes.oneOfType([PropTypes.string, PropTypes.array]),
style: ViewPropTypes.style,
style: View.propTypes.style,
};
8 changes: 4 additions & 4 deletions src/component/form.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import React from 'react';
import { View, TextPropTypes, ViewPropTypes, StyleSheet } from 'react-native';
import { View, Text as RNText, StyleSheet } from 'react-native';
import PropTypes from 'prop-types';
import Text from './text';
import { color, font } from './style';
Expand All @@ -25,7 +25,7 @@ export const FormStretcher = ({ children, style }) => (

FormStretcher.propTypes = {
children: PropTypes.node,
style: ViewPropTypes.style,
style: View.propTypes.style,
};

//
Expand All @@ -46,7 +46,7 @@ export const FormText = ({ children, style }) => (

FormText.propTypes = {
children: PropTypes.string,
style: TextPropTypes.style,
style: RNText.propTypes.style,
};

//
Expand All @@ -68,5 +68,5 @@ export const FormSubText = ({ children, style }) => (

FormSubText.propTypes = {
children: PropTypes.oneOfType([PropTypes.string, PropTypes.array]),
style: TextPropTypes.style,
style: RNText.propTypes.style,
};
6 changes: 3 additions & 3 deletions src/component/header.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import React from 'react';
import { View, ViewPropTypes, StyleSheet } from 'react-native';
import { View, StyleSheet } from 'react-native';
import PropTypes from 'prop-types';
import Text from './text';
import { color } from './style';
Expand Down Expand Up @@ -43,7 +43,7 @@ export const Header = ({ style, children, color, shadow, separator }) => (
);

Header.propTypes = {
style: ViewPropTypes.style,
style: View.propTypes.style,
children: PropTypes.node,
color: PropTypes.string,
shadow: PropTypes.bool,
Expand Down Expand Up @@ -86,7 +86,7 @@ export const Title = ({ title = '', style, children }) => (

Title.propTypes = {
title: PropTypes.string,
style: ViewPropTypes.style,
style: View.propTypes.style,
children: PropTypes.node,
};

Expand Down
4 changes: 2 additions & 2 deletions src/component/icon.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import React from 'react';
import { Image, ViewPropTypes } from 'react-native';
import { Image, View } from 'react-native';
import PropTypes from 'prop-types';

const Icon = ({ image, style }) => (
Expand All @@ -8,7 +8,7 @@ const Icon = ({ image, style }) => (

Icon.propTypes = {
image: PropTypes.string.isRequired,
style: ViewPropTypes.style,
style: View.propTypes.style,
};

export default Icon;
6 changes: 3 additions & 3 deletions src/component/input.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import React, { Component } from 'react';
import {
TextInput as RNTextInput,
TextPropTypes,
Text as RNText,
StyleSheet,
} from 'react-native';
import PropTypes from 'prop-types';
Expand Down Expand Up @@ -33,7 +33,7 @@ export const TextInput = ({ style, ...props }) => (
);

TextInput.propTypes = {
style: TextPropTypes.style,
style: RNText.propTypes.style,
};

//
Expand Down Expand Up @@ -73,7 +73,7 @@ HorizontalExpandingTextInput.propTypes = {
value: PropTypes.string,
charWidth: PropTypes.number.isRequired,
onChangeText: PropTypes.func,
style: TextPropTypes.style,
style: RNText.propTypes.style,
};

export default TextInput;
10 changes: 5 additions & 5 deletions src/component/label.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import React from 'react';
import { View, ViewPropTypes, TextPropTypes, StyleSheet } from 'react-native';
import { View, Text as RNText, StyleSheet } from 'react-native';
import PropTypes from 'prop-types';
import Text from './text';
import { font } from './style';
Expand Down Expand Up @@ -31,7 +31,7 @@ export const BalanceLabel = ({ children, style }) => (

BalanceLabel.propTypes = {
children: PropTypes.node.isRequired,
style: ViewPropTypes.style,
style: View.propTypes.style,
};

export const BalanceLabelNumeral = ({ children, style }) => (
Expand All @@ -40,15 +40,15 @@ export const BalanceLabelNumeral = ({ children, style }) => (

BalanceLabelNumeral.propTypes = {
children: PropTypes.string.isRequired,
style: TextPropTypes.style,
style: RNText.propTypes.style,
};

export const BalanceLabelUnit = ({ children, style }) =>
children ? <Text style={[balanceStyles.unit, style]}>{children}</Text> : null;

BalanceLabelUnit.propTypes = {
children: PropTypes.string,
style: TextPropTypes.style,
style: RNText.propTypes.style,
};

//
Expand Down Expand Up @@ -82,5 +82,5 @@ export const SmallBalanceLabel = ({ children, unit, style }) => (
SmallBalanceLabel.propTypes = {
children: PropTypes.string.isRequired,
unit: PropTypes.string,
style: TextPropTypes.style,
style: RNText.propTypes.style,
};
16 changes: 5 additions & 11 deletions src/component/list.js
Original file line number Diff line number Diff line change
@@ -1,11 +1,5 @@
import React, { Component, PureComponent } from 'react';
import {
View,
ListView,
TouchableOpacity,
ViewPropTypes,
StyleSheet,
} from 'react-native';
import { View, ListView, TouchableOpacity, StyleSheet } from 'react-native';
import PropTypes from 'prop-types';
import Text from './text';
import Icon from './icon';
Expand All @@ -31,7 +25,7 @@ export const ListContent = ({ children, style }) => (

ListContent.propTypes = {
children: PropTypes.node,
style: ViewPropTypes.style,
style: View.propTypes.style,
};

//
Expand Down Expand Up @@ -100,7 +94,7 @@ export class ListItem extends PureComponent {
ListItem.propTypes = {
onSelect: PropTypes.func,
children: PropTypes.node,
style: ViewPropTypes.style,
style: View.propTypes.style,
};

//
Expand All @@ -119,7 +113,7 @@ export const ListHeader = ({ style, children }) => (

ListHeader.propTypes = {
children: PropTypes.node,
style: ViewPropTypes.style,
style: View.propTypes.style,
};

//
Expand Down Expand Up @@ -187,5 +181,5 @@ export const SettingHeader = ({ name, style }) => (

SettingHeader.propTypes = {
name: PropTypes.string.isRequired,
style: ViewPropTypes.style,
style: View.propTypes.style,
};
Loading