Cell

Install

import React from 'react';
import { Cell } from 'vant-react';

Usage

Basic Usage

<Cell
      title={{ text: 'Title', fontSize: '14px' }}
      content={{ text: 'Content', fontSize: '12px' }}
    />
<Cell
      title={{ text: 'Title', fontSize: '14px' }}
      content={{ text: 'Content', fontSize: '12px' }}
      description={{ text: 'description', fontSize: '12px' }}
    />

Cell Icon

<Cell titleIcon={{ name: 'location-o', size: '12px' }}
      title={{ text: 'Title', fontSize: '14px' }}
      contentIcon={{ name: 'arrow', size: '12px' }}
      content={{ text: 'Content', fontSize: '12px' }} 
    />

Cell Tag

<Cell
      title={{ text: 'Title', fontSize: '14px' }}
      Tag={<Tag type='danger' text='Tag' />}
      content={{ text: 'Content', fontSize: '12px' }}
    />

Round Cell

<Cell title={{ text: 'Title', fontSize: '14px' }} round />

Value Only

<Cell title={{ text: 'Title', fontSize: '14px' }} round />

URL

<Cell
      title={{ text: 'URL', fontSize: '14px' }}
      url='www.google.com'
      replace
    />

Action

<Cell
      title={{ text: 'Click', fontSize: '14px' }}
      click={(e) => {
        alert(e);
      }}
    />

API

Props

Event

Last updated