1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374 |
- /*
- * 搜索结果页面
- */
- import React, { Component } from "react";
- import {
- Platform,
- StyleSheet,
- Text,
- View,
- Image,
- TouchableOpacity,
- ImageBackground,
- Button,
- StatusBar,
- Modal,
- TouchableHighlight,
- DeviceEventEmitter,
- FlatList,
- TextInput
- } from "react-native";
- import BasePage from "./BasePage";
- import Dimensions from './utils/dimensions';
- import ShopBox from "./components/ShopBox";
- import TopicTitle from './components/TopicTitle';
- import ScrollRow from './components/ScrollRow';
- export default class SearchResult extends BasePage {
- state = {
- text: '123123123123'
- };
- searchBox = () => {
- return (
- <View style={styles.searchBox}>
- <TextInput
- style={styles.searchInput}
- onChangeText={(text) => this.setState({ text })}
- value={this.state.text}
- renderItem={item => this.renderItem(item)}
- />
- </View>
- )
- }
- renderItem = (item) =>{
- return (
- <View>
-
- </View>
- )
- }
- render() {
- return (
- <FlatList
- ListHeaderComponent={() => this.searchBox()}
- />
- )
- }
- }
- const styles = StyleSheet.create({
- searchBox: {
- width: Dimensions.width,
- height: 60,
- alignItems: 'center',
- justifyContent: 'center',
- backgroundColor: '#f6f7f8'
- },
- searchInput: {
- width: '88.5%',
- height: 40,
- borderRadius: 20,
- backgroundColor: '#fff'
- }
- })
|