Sha256: 43e1550419197cb9a44cb9a8c0037a3a9f33c5ff73573d84f1e521de89286974
Contents?: true
Size: 1.55 KB
Versions: 7
Compression:
Stored size: 1.55 KB
Contents
import React from 'react' import { Button, Filter, Flex, Select, TextInput } from '../..' const SortingChangeCallback = (sortOptions) => { alert(JSON.stringify(sortOptions[0])) } const FilterPlacement = (props) => { const options = [ { value: 'USA' }, { value: 'Canada' }, { value: 'Brazil' }, { value: 'Philippines' }, { value: 'A Galaxy Far Far Away Like Really Far Away' }, ] return ( <> <Filter double onSortChange={SortingChangeCallback} placement={"right"} results={1} sortOptions={{ popularity: 'Popularity', // eslint-disable-next-line manager_title: 'Manager\'s Title', // eslint-disable-next-line manager_name: 'Manager\'s Name', }} sortValue={[{ name: 'popularity', dir: 'desc' }]} {...props} > <TextInput label="Example Text Field" placeholder="Enter Text" {...props} /> <Select blankSelection="Select One..." label="Example Collection Select" name="Collection Select" options={options} {...props} /> <Flex spacing="between" {...props} > <Button text="Apply" {...props} /> <Button text="Clear" variant="secondary" {...props} /> </Flex> </Filter> </> ) } export default FilterPlacement
Version data entries
7 entries across 7 versions & 1 rubygems