Sha256: ecc24f97530247f9240c6db49dd179ec91f69c6844382d99198294c4e21a399f
Contents?: true
Size: 882 Bytes
Versions: 38
Compression:
Stored size: 882 Bytes
Contents
import React from 'react'; import PropTypes from 'prop-types'; import SearchBar from 'foremanReact/components/SearchBar'; import { getControllerSearchProps } from 'foremanReact/constants'; import { hostsController, hostQuerySearchID } from '../../JobWizardConstants'; export const HostSearch = ({ value, setValue }) => { const props = getControllerSearchProps(hostsController, hostQuerySearchID); return ( <div className="foreman-search-field"> <SearchBar data={{ ...props, autocomplete: { id: hostQuerySearchID, url: '/hosts/auto_complete_search', searchQuery: value, }, }} onSearch={null} onSearchChange={search => setValue(search)} /> </div> ); }; HostSearch.propTypes = { value: PropTypes.string.isRequired, setValue: PropTypes.func.isRequired, };
Version data entries
38 entries across 38 versions & 1 rubygems