linear-react-components-ui 1.1.22-beta.11 → 1.1.22-beta.12

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.
@@ -141,9 +141,6 @@ const SimpleSelect = props => {
141
141
  if (props.onBlur) {
142
142
  const event = getSelectEvent(selected);
143
143
  props.onBlur(event);
144
- if (selected && opened) {
145
- onSelect(selected);
146
- }
147
144
  if (selected && descriptionKeyIsString && inputText !== selected[descriptionKey] || !descriptionKeyIsString && inputText !== descriptionKey(selected)) {
148
145
  setSelected(null);
149
146
  setInputText(inputText);
@@ -223,6 +220,9 @@ const SimpleSelect = props => {
223
220
  setSelected(newCurrent);
224
221
  if (descriptionKeyIsString) setInputText(newCurrent ? newCurrent[descriptionKey] : '');else setInputText(newCurrent ? descriptionKey(newCurrent) : '');
225
222
  }
223
+ if (dataSourceWithAllOptions.length === 0 && inputText) {
224
+ setInputText('');
225
+ }
226
226
  }, [dataSourceWithAllOptions.length, value]);
227
227
  (0, _react.useEffect)(() => {
228
228
  if (!_lodash.default.isEqual(dataCombo, dataSourceWithAllOptions)) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "linear-react-components-ui",
3
- "version": "1.1.22-beta.11",
3
+ "version": "1.1.22-beta.12",
4
4
  "description": "Linear Sistemas ReactJs Components",
5
5
  "main": "lib/index.js",
6
6
  "module": "lib/index.cjs",
@@ -8,7 +8,7 @@
8
8
  "lib"
9
9
  ],
10
10
  "scripts": {
11
- "lib": "babel src/lib/ -d lib/ --extensions \".js,.jsx,.ts,.tsx\" --ignore **/*.spec.tsx && babel src/lib/assets -d lib/assets --copy-files && npm run lib:types",
11
+ "lib": "rm -rf lib && babel src/lib/ -d lib/ --extensions \".js,.jsx,.ts,.tsx\" --ignore **/*.spec.tsx && babel src/lib/assets -d lib/assets --copy-files && npm run lib:types",
12
12
  "lib:types": "tsup --dts-only --dts --external react",
13
13
  "demo": "node scripts/start.js",
14
14
  "demo:prod": "webpack --config ./config/webpack.config.js --mode production",