3
0

BaseContainer.js 574 B

12345678910111213141516171819202122232425
  1. import React from 'react';
  2. import { StyleSheet, Text, View, TextInput, Button } from 'react-native';
  3. import Types from '../lib/Types';
  4. export default function BaseContainer(props) {
  5. let {
  6. selected,
  7. width,
  8. height,
  9. ...restProps
  10. } = props;
  11. if(!width) width = BaseContainer.Inputs.width.default;
  12. if(!height) height = BaseContainer.Inputs.height.default;
  13. return (
  14. <View {...restProps} style={{width, height}}>
  15. </View>
  16. );
  17. }
  18. BaseContainer.Inputs = {
  19. width: new Types.Integer().require().default(50),
  20. height: new Types.Integer().require().default(50)
  21. }