react-search-autocomplete
Advanced tools
Comparing version 1.0.9 to 1.1.0
@@ -5,3 +5,3 @@ { | ||
"license": "MIT", | ||
"version": "1.0.9", | ||
"version": "1.1.0", | ||
"description": "A search box for React", | ||
@@ -8,0 +8,0 @@ "main": "dist/index.js", |
133
README.md
@@ -100,2 +100,3 @@ ![travis](https://travis-ci.com/sickdyd/react-search-autocomplete.svg?branch=master) | ||
{ | ||
items, | ||
// The list of items that can be filtered, it can be an array of | ||
@@ -105,74 +106,70 @@ // any type of object. By default the search will be done on the | ||
// prop. | ||
items, | ||
// By default set to: | ||
// { | ||
// shouldSort: true, | ||
// threshold: 0.6, | ||
// location: 0, | ||
// distance: 100, | ||
// maxPatternLength: 32, | ||
// minMatchCharLength: 1, | ||
// keys: [ | ||
// "name", | ||
// ] | ||
// } | ||
// | ||
// To know more about fuse params, visit https://fusejs.io/ | ||
fuseOptions, | ||
// Default value: true. If set to false, the items will | ||
// not be stored in sessionStorage, and each time onSearch | ||
// is called, cached will be false. | ||
useCaching, | ||
// Default value: 200. When the user is typing, before | ||
// calling onSearch wait this amount of ms. | ||
inputDebounce, | ||
// The callback function called when the user is searching. | ||
onSearch, | ||
// The callback function called when the user selects an item | ||
// from the filtered list. | ||
onSelect, | ||
// The callback function called when the user focuses the input. | ||
onFocus, | ||
// Default value: true. If set to false, the icon is hidden. | ||
showIcon, | ||
// Default value: 10. The max number of results to show at once. | ||
maxResults, | ||
// Default value: "". The placeholder of the search box. | ||
placeholder, | ||
// Default value: false. If set to true, automatically | ||
// set focus on the input. | ||
autoFocus, | ||
// The styling prop allows you to customize the | ||
// look of the searchbox | ||
// Default values: | ||
// { | ||
// height: "44px", | ||
// border: "1px solid #dfe1e5", | ||
// borderRadius: "24px", | ||
// backgroundColor: "white", | ||
// boxShadow: "rgba(32, 33, 36, 0.28) 0px 1px 6px 0px", | ||
// hoverBackgroundColor: "#eee", | ||
// color: "#212121", | ||
// fontSize: "16px", | ||
// fontFamily: "Arial", | ||
// iconColor: "grey", | ||
// lineColor: "rgb(232, 234, 237)", | ||
// placeholderColor: "grey", | ||
// }; | ||
// | ||
// For example, if you want to change the background | ||
// color you can pass it in the props: | ||
// styling={ | ||
// { | ||
// backgroundColor: "black" | ||
// } | ||
// } | ||
styling | ||
fuseOptions, | ||
// By default set to: | ||
// { | ||
// shouldSort: true, | ||
// threshold: 0.6, | ||
// location: 0, | ||
// distance: 100, | ||
// maxPatternLength: 32, | ||
// minMatchCharLength: 1, | ||
// keys: [ | ||
// "name", | ||
// ] | ||
// } | ||
// | ||
// To know more about fuse params, visit https://fusejs.io/ | ||
useCaching, | ||
// Default value: true. If set to false, the items will | ||
// not be stored in sessionStorage, and each time onSearch | ||
// is called, cached will be false. | ||
inputDebounce, | ||
// Default value: 200. When the user is typing, before | ||
// calling onSearch wait this amount of ms. | ||
onSearch, | ||
// The callback function called when the user is searching. | ||
onSelect, | ||
// The callback function called when the user selects an item | ||
// from the filtered list. | ||
onFocus, | ||
// The callback function called when the user focuses the input. | ||
showIcon, | ||
// Default value: true. If set to false, the icon is hidden. | ||
maxResults, | ||
// Default value: 10. The max number of results to show at once. | ||
placeholder, | ||
// Default value: "". The placeholder of the search box. | ||
autoFocus, | ||
// Default value: false. If set to true, automatically | ||
// set focus on the input. | ||
styling | ||
// The styling prop allows you to customize the | ||
// look of the searchbox | ||
// Default values: | ||
// { | ||
// height: "44px", | ||
// border: "1px solid #dfe1e5", | ||
// borderRadius: "24px", | ||
// backgroundColor: "white", | ||
// boxShadow: "rgba(32, 33, 36, 0.28) 0px 1px 6px 0px", | ||
// hoverBackgroundColor: "#eee", | ||
// color: "#212121", | ||
// fontSize: "16px", | ||
// fontFamily: "Arial", | ||
// iconColor: "grey", | ||
// lineColor: "rgb(232, 234, 237)", | ||
// placeholderColor: "grey", | ||
// }; | ||
// | ||
// For example, if you want to change the background | ||
// color you can pass it in the props: | ||
// styling={ | ||
// { | ||
// backgroundColor: "black" | ||
// } | ||
// } | ||
} | ||
``` | ||
--- | ||
### License | ||
MIT |
58448
174