@uncinc/uncinc-react-kitchen-sink 2.2.3 → 2.2.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -22,6 +22,7 @@ const ApiAutocomplete = ({
22
22
  defaultValue,
23
23
  onSelectItem,
24
24
  queryParameter = 'q',
25
+ getSuggestionValue,
25
26
  ...props
26
27
  }) => {
27
28
  const [queryInput, setQuery] = useState(defaultValue || '');
@@ -58,9 +59,7 @@ const ApiAutocomplete = ({
58
59
  onSuggestionsClearRequested: () => {
59
60
  setResults([]);
60
61
  },
61
- getSuggestionValue: item => {
62
- return item.name;
63
- },
62
+ getSuggestionValue: getSuggestionValue,
64
63
  renderSuggestion: (item, attributes) => {
65
64
  return renderItem(item, attributes.isHighlighted);
66
65
  },
@@ -88,4 +87,9 @@ const ApiAutocomplete = ({
88
87
  });
89
88
  };
90
89
 
90
+ ApiAutocomplete.defaultProps = {
91
+ getSuggestionValue: item => {
92
+ return item.name;
93
+ }
94
+ };
91
95
  export default ApiAutocomplete;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@uncinc/uncinc-react-kitchen-sink",
3
- "version": "2.2.3",
3
+ "version": "2.2.4",
4
4
  "description": "Default React components that are easily extended.",
5
5
  "author": "uncinc",
6
6
  "license": "MIT",
@@ -1,3 +0,0 @@
1
- .WysiwygField {
2
- margin-right: 200px;
3
- }