UNPKG

@darwino/darwino-react-bootstrap

Version:

A set of Javascript classes and utilities

27 lines (24 loc) 821 B
/* * (c) Copyright Darwino Inc. 2014-2017. */ import React, { Component } from "react"; import { ListGroup, ListGroupItem } from 'react-bootstrap'; import { BaseListPicker } from '@darwino/darwino-react'; /* * List picker */ class ListPicker extends BaseListPicker { renderBody() { return /*#__PURE__*/React.createElement("div", null, /*#__PURE__*/React.createElement(ListGroup, { style: { maxHeight: this.props.maxHeight || 400, overflow: "auto" } }, this.dataFetcher.getRows(0, this.dataFetcher.getRowCount()).map((value, index) => /*#__PURE__*/React.createElement(ListGroupItem, { key: index, onClick: e => this.selectValue(this.itemValue(value)) }, this.renderItem(value, index))))); } } export default ListPicker; //# sourceMappingURL=ListPicker.js.map