@daoyi/nmtl-ui 2.0.1-beta.70 → 2.0.1-beta.71

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.
@@ -83,14 +83,13 @@ var useAutocomplete = (_ref => {
83
83
  }), searchIcon && /*#__PURE__*/React__default.createElement(SearchOutlined, {
84
84
  className: "autocomplete__icon",
85
85
  onClick: event => {
86
- setCurrentDefaultValue({
87
- label: currentResult,
86
+ const tmpObj = {
87
+ labels: currentResult,
88
88
  value: currentResult
89
- });
90
- return onEnter(event, {
91
- label: currentResult,
92
- value: currentResult
93
- });
89
+ };
90
+ if (!currentResult) return tmpObj;
91
+ setCurrentDefaultValue(tmpObj);
92
+ return onEnter(event, tmpObj);
94
93
  }
95
94
  }), params.InputProps.endAdornment)
96
95
  }
@@ -103,7 +102,7 @@ var useAutocomplete = (_ref => {
103
102
  };
104
103
  });
105
104
 
106
- var css_248z = ".autocomplete .MuiAutocomplete-inputRoot[class*='MuiOutlinedInput-root'] {\n padding: 0px 8px; }\n\n.autocomplete .MuiChip-deleteIcon {\n width: 16px;\n height: 16px; }\n\n.autocomplete__icon {\n font-size: 1.25rem;\n margin-right: 8px;\n cursor: pointer; }\n\n.autocomplete--showSearchIcon .MuiAutocomplete-inputRoot[class*='MuiOutlinedInput-root'] {\n display: flex;\n flex-wrap: nowrap;\n padding: 4px 8px; }\n";
105
+ var css_248z = ".autocomplete .MuiAutocomplete-inputRoot[class*='MuiOutlinedInput-root'] {\n flex-wrap: wrap;\n padding: 0px 8px; }\n\n.autocomplete .MuiChip-deleteIcon {\n width: 16px;\n height: 16px; }\n\n.autocomplete__icon {\n font-size: 1.25rem;\n margin-right: 8px;\n cursor: pointer; }\n\n.autocomplete--showSearchIcon .MuiAutocomplete-inputRoot[class*='MuiOutlinedInput-root'] {\n display: flex;\n flex-wrap: nowrap;\n padding: 4px 8px; }\n";
107
106
  styleInject(css_248z);
108
107
 
109
108
  var Autocomplete = function Autocomplete(props) {
@@ -1,4 +1,4 @@
1
- export { A as default } from './Autocomplete-429c839b.js';
1
+ export { A as default } from './Autocomplete-e62927dc.js';
2
2
  import './_rollupPluginBabelHelpers-a52356f6.js';
3
3
  import 'react';
4
4
  import 'prop-types';
@@ -6,14 +6,14 @@ import { d as debounce_1 } from './debounce-127da66c.js';
6
6
  import { useHistory, useRouteMatch, NavLink } from 'react-router-dom';
7
7
  import { Typography, IconButton } from '@material-ui/core';
8
8
  import { SearchOutlined } from '@material-ui/icons';
9
- import { K as KeywordSearch } from './KeywordSearch-ae74e8e2.js';
9
+ import { K as KeywordSearch } from './KeywordSearch-3af0c402.js';
10
10
  import { S as Select } from './Select-0f131640.js';
11
11
  import { c as checkLanguageSupport, D as Drawer, d as defaultSupportLanguage } from './Drawer-fb5bc1ec.js';
12
12
  import { s as styleInject } from './style-inject.es-1f59c1d0.js';
13
13
  import './isObjectLike-e111475d.js';
14
14
  import './_commonjsHelpers-70de2c37.js';
15
15
  import 'axios';
16
- import './Autocomplete-429c839b.js';
16
+ import './Autocomplete-e62927dc.js';
17
17
  import '@material-ui/lab';
18
18
  import './Empty-e50b760e.js';
19
19
 
@@ -4,7 +4,7 @@ import PropTypes from 'prop-types';
4
4
  import { c as classNames } from './index-ef96775f.js';
5
5
  import axios from 'axios';
6
6
  import { s as styleInject } from './style-inject.es-1f59c1d0.js';
7
- import { A as Autocomplete } from './Autocomplete-429c839b.js';
7
+ import { A as Autocomplete } from './Autocomplete-e62927dc.js';
8
8
 
9
9
  var css_248z = ".keywordSearch {\n border-radius: 4px;\n width: 100%;\n margin-right: 14px; }\n .keywordSearch--animation .autocomplete {\n transition: max-width 0.3s ease-out;\n max-width: 240px; }\n .keywordSearch--focus {\n flex: 1; }\n .keywordSearch--focus .autocomplete {\n max-width: 100%; }\n .keywordSearch .MuiAutocomplete-hasPopupIcon.MuiAutocomplete-hasClearIcon .MuiAutocomplete-inputRoot[class*='MuiOutlinedInput-root'] {\n border-radius: 10px;\n background-color: #ffffff66; }\n";
10
10
  styleInject(css_248z);
@@ -1,11 +1,11 @@
1
- export { K as default } from './KeywordSearch-ae74e8e2.js';
1
+ export { K as default } from './KeywordSearch-3af0c402.js';
2
2
  import './_rollupPluginBabelHelpers-a52356f6.js';
3
3
  import 'react';
4
4
  import 'prop-types';
5
5
  import './index-ef96775f.js';
6
6
  import 'axios';
7
7
  import './style-inject.es-1f59c1d0.js';
8
- import './Autocomplete-429c839b.js';
8
+ import './Autocomplete-e62927dc.js';
9
9
  import './debounce-127da66c.js';
10
10
  import './isObjectLike-e111475d.js';
11
11
  import './_commonjsHelpers-70de2c37.js';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@daoyi/nmtl-ui",
3
- "version": "2.0.1-beta.70",
3
+ "version": "2.0.1-beta.71",
4
4
  "description": "This project is to be used as a starter kit for building React component using Storybook and Rollup",
5
5
  "author": "daoyi",
6
6
  "main": "lib/index.js",