UNPKG

1.52 kBJavaScriptView Raw
1var __rest = (this && this.__rest) || function (s, e) {
2 var t = {};
3 for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
4 t[p] = s[p];
5 if (s != null && typeof Object.getOwnPropertySymbols === "function")
6 for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
7 if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
8 t[p[i]] = s[p[i]];
9 }
10 return t;
11};
12import React from 'react';
13import { StyleSheet } from 'react-native';
14import { withTheme } from '../config';
15import Input from '../input/Input';
16const ListItemInput = (_a) => {
17 var { inputStyle, inputContainerStyle, containerStyle } = _a, props = __rest(_a, ["inputStyle", "inputContainerStyle", "containerStyle"]);
18 return (<Input renderErrorMessage={false} {...props} inputStyle={StyleSheet.flatten([styles.input, inputStyle])} inputContainerStyle={StyleSheet.flatten([
19 styles.inputContainer,
20 inputContainerStyle,
21 ])} containerStyle={StyleSheet.flatten([styles.container, containerStyle])}/>);
22};
23const styles = StyleSheet.create({
24 container: {
25 flex: 1,
26 paddingRight: 0,
27 },
28 inputContainer: {
29 flex: 1,
30 borderBottomWidth: 0,
31 width: null,
32 height: null,
33 },
34 input: {
35 flex: 1,
36 textAlign: 'right',
37 width: null,
38 height: null,
39 },
40});
41export default withTheme(ListItemInput, 'ListItemInput');
42
\No newline at end of file