Как сделать кастомную карту в реагировать на родную как бутстрап - PullRequest
0 голосов
/ 27 сентября 2019

Я хочу создать собственную карту в собственном режиме, как мы это делаем, используя html и css с верхним изображением, заголовком карты и текстом карты

Ответы [ 2 ]

0 голосов
/ 27 сентября 2019

Используйте для этого собственный компонент базовых карт.

import React, { Component } from 'react';
import { Image } from 'react-native';
import { Container, Header, Content, Card, CardItem, Thumbnail, Text, Button, Icon, Left, Body, Right } from 'native-base';
export default class CardImageExample extends Component {
  render() {
    return (
      <Container>
        <Header />
        <Content>
          <Card>
            <CardItem>
              <Left>
                <Thumbnail source={{uri: 'Image URL'}} />
                <Body>
                  <Text>NativeBase</Text>
                  <Text note>GeekyAnts</Text>
                </Body>
              </Left>
            </CardItem>
            <CardItem cardBody>
              <Image source={{uri: 'Image URL'}} style={{height: 200, width: null, flex: 1}}/>
            </CardItem>
            <CardItem>
              <Left>
                <Button transparent>
                  <Icon active name="thumbs-up" />
                  <Text>12 Likes</Text>
                </Button>
              </Left>
              <Body>
                <Button transparent>
                  <Icon active name="chatbubbles" />
                  <Text>4 Comments</Text>
                </Button>
              </Body>
              <Right>
                <Text>11h ago</Text>
              </Right>
            </CardItem>
          </Card>
        </Content>
      </Container>
    );
  }
}

Ссылка: - https://docs.nativebase.io/Components.html#card-image-headref

0 голосов
/ 27 сентября 2019

Посмотрите на эту пару, есть определенный компонент:

https://react -native-training.github.io / реагировать-native-elements / docs / card.html

Добро пожаловать на сайт PullRequest, где вы можете задавать вопросы и получать ответы от других членов сообщества.
...