How to use the antd-mobile.List.Item function in antd-mobile

To help you get started, we’ve selected a few antd-mobile examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github uquinnhau / app_job / src / component / msg / msg.js View on Github external
render(){

		const Item = List.Item
		const Brief = Item.Brief
		const userid = this.props.user._id
		const userinfo = this.props.chat.users
		// console.log(this.props)
		const msgGroup = {}
		this.props.chat.chatmsg.forEach(v=>{
			msgGroup[v.chatid] = msgGroup[v.chatid] || []
			msgGroup[v.chatid].push(v)
		})
		
		const chatList = Object.values(msgGroup).sort((a,b)=>{
			const a_last = this.getLast(a).create_time
			const b_last = this.getLast(b).create_time
			return b_last - a_last
		})
github LeeRayno / react-antd-mobile-demo / src / components / ListItem / index.js View on Github external
/**
 * Created by Administrator on 2017/8/10.
 */
import React, { Component } from 'react'
import { List, Button } from 'antd-mobile'
import { connect } from 'react-redux'
import { saveListData } from '../../redux/actions'

import './listItem.less'

const Item = List.Item

class ListItems extends Component {

	// 确认参会
	ensurePart = () => {
		this.props.ensurePart()
	}

	// 取消参会
	cancelPart = () => {
		this.props.cancelPart()
	}

	//签到
	sign = () => {
		this.props.sign()
github zhang14725804 / notebook / react-vue / react-chat / src / components / user / user.js View on Github external
render(){
    console.log(this.props)
    const Item=List.Item
    const Brief=Item.Brief
    //从redux中取值,之前authRoute组件已将获取到了数据
    //记得判空
    return this.props.name?(
      <div style="{{position:&quot;relative&quot;,zIndex:11}}">
        }
        title={this.props.name}
        message={this.props.type==='boss'?this.props.company:null}&gt;
        '简介'}&gt;
          
            {this.props.title}
            {this.props.desc.split('\n').map(d=&gt;{d})}
            {this.props.money?薪资:{this.props.money}:null}
          
        
        </div>
github zhangfan6644777 / Redux-cnode / src / components / Topic / List / qwe.js View on Github external
import React from 'react';
import {
  RefreshControl,
  ListView,
  List
} from 'antd-mobile';
const Item = List.Item;
const Brief = Item.Brief;
import {
  Link
} from 'react-router';


let pageIndex = 0;

class App extends React.Component {
  constructor(props) {
    super(props);
    const dataSource = new ListView.DataSource({
      rowHasChanged: (row1, row2) => row1 !== row2,
    });
    console.log(dataSource)
    this.onRefresh = this.onRefresh.bind(this)
github layupbolon / cnode-with-umi / src / components / list / index.js View on Github external
import React from 'react';
import { List } from 'antd-mobile';
import router from 'umi/router';

import { dataFormat } from '../../utils/index';

const Item = List.Item;

function ListView({ data }) {
    if (!data || data.length &lt; 1) return null;
    return (
        
            {data.map((item, index) =&gt; {
                return (
                     router.push(`/topicDetail/${item.id}`)}
                    &gt;
                        {item.title}
                    
                );
            })}
github zhangfan6644777 / Redux-cnode / src / components / Article / Content / Content.js View on Github external
import React from 'react';
import {
	List,
	Card,
	Button
} from 'antd-mobile';
const Item = List.Item;
const Brief = Item.Brief;
import {
	Link
} from 'react-router';

import GetTime from '../../../utils/GetTime';

require('./Content.less')
class Content extends React.Component {
	constructor(...arg) {
		super(...arg);
		this.is_collect = false;
	}
	render() {
		let _this = this;
		let {
github KieSun / Chat-Buy-React / chat-buy-react / src / components / goods / goodsList.jsx View on Github external
import React from "react";
import { List, Stepper } from "antd-mobile";
import ImmutablePropTypes from "react-immutable-proptypes";
import PropTypes from "prop-types";

const Item = List.Item;
const Brief = Item.Brief;

function getCount(shopCart, id) {
  let obj = shopCart.find(value =&gt; {
    return id === value.get("id");
  });
  return obj ? obj.get("count") : 0;
}

const GoodsList = ({ goodsList, addToCart, shopCart }) =&gt; {
  return (
    
      {goodsList.map(v =&gt; (
github zhangfan6644777 / Redux-cnode / src / components / Message / MessageList.js View on Github external
import React from 'react';
import {
	Card,
	Tabs,
	WhiteSpace,
	List,
	Badge
} from 'antd-mobile';
const Item = List.Item;
const Brief = Item.Brief;
import {
	Link
} from 'react-router';
const TabPane = Tabs.TabPane;
require('./MessageList.less')
import GetTime from '../../utils/GetTime';

class Message extends React.Component {
	constructor(){
		super();
		this.handleTabClick=this.handleTabClick.bind(this);
	}
	handleTabClick(key) {
		let {dispatch,actions,state,login}=this.props;
		if(key==2&&(state.hasnot_read_messages.length==0)){
github wuchujiang / react-lol-spa / src / Component / search / history.jsx View on Github external
import React, {Component} from 'react';
import { Link } from 'react-router';
import className from 'classnames';
import { Icon, List, Modal } from 'antd-mobile';
import { is, fromJS} from 'immutable';
import {Tool} from 'src/Config/Tool';
const Item = List.Item;
const Brief = Item.Brief;
export default class PanelTab extends Component {
    constructor(props) {
        super(props);
        this.state = {
            index: 0,
            history: []
        };

    }

    shouldComponentUpdate(nextProps, nextState) {
        return !is(fromJS(this.props), fromJS(nextProps)) || !is(fromJS(this.state),fromJS(nextState))
    }

    componentDidMount() {
github SusieChang / react-app / src / containers / Settings / guestList.js View on Github external
import React, {Component} from 'react'
import {List, WhiteSpace, Switch, Toast} from 'antd-mobile'
import {createForm} from 'rc-form'
import './style.less'

const Item = List.Item

class Setting extends Component {
  state = {
    weiboChecked: false,
    wechatChecked: false,
    githubChecked: false,
    imgChecked: false,
    pasteChecked: false
  }

  handleNotComplete = () => {
    Toast.info('功能尚未开发', 1.5)
  }

  render() {
    const {getFieldProps} = this.props.form