import React from 'react'; import { Row, Col } from 'react-styled-flexboxgrid'; import forceArray from 'force-array'; import { FormGroup, Input, FormLabel, ViewContainer, StatusLoader, Select } from 'joyent-ui-toolkit'; import Item from './item'; export default ({ instances, loading, handleChange = () => null, onAction = () => null, handleSubmit, ...rest }) => { const _instances = forceArray(instances); const items = _instances.map((instance, i, all) => ( )); const _loading = !items.length && loading ? ( ) : null; return (
handleSubmit(ctx => handleChange(ctx))} onSubmit={handleSubmit} > Filter instances Sort {_loading} {items}
); };