@nebula.js/stardust 3.0.0-alpha2 → 3.0.0-alpha5

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.
package/core/esm/dev.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /*
2
- * @nebula.js/stardust v3.0.0-alpha2
2
+ * @nebula.js/stardust v3.0.0-alpha5
3
3
  * Copyright (c) 2022 QlikTech International AB
4
4
  * Released under the MIT license.
5
5
  */
@@ -11424,7 +11424,7 @@ function create$3(definition) {
11424
11424
  return cache[key];
11425
11425
  }
11426
11426
 
11427
- const NEBULA_VERSION_HASH = "9c10" ;
11427
+ const NEBULA_VERSION_HASH = "6da9" ;
11428
11428
  ClassNameGenerator.configure(componentName => {
11429
11429
 
11430
11430
  return "njs-".concat(NEBULA_VERSION_HASH, "-").concat(componentName.replace('Mui', ''));
@@ -11997,7 +11997,7 @@ function boot(_ref2) {
11997
11997
  const appRef = React__default.createRef();
11998
11998
  const element = document.createElement('div');
11999
11999
  element.style.display = 'none';
12000
- element.setAttribute('data-nebulajs-version', "3.0.0-alpha2" );
12000
+ element.setAttribute('data-nebulajs-version', "3.0.0-alpha5" );
12001
12001
  element.setAttribute('data-app-id', app.id);
12002
12002
  document.body.appendChild(element);
12003
12003
  ReactDOM.render( /*#__PURE__*/React__default.createElement(NebulaApp, {
@@ -14412,7 +14412,7 @@ function ListBox(_ref2) {
14412
14412
  if (typeof setCount === 'function' && layout) {
14413
14413
  setCount(layout.qListObject.qSize.qcy);
14414
14414
  }
14415
- }, [layout]);
14415
+ }, [layout, layout && layout.qListObject.qSize.qcy]);
14416
14416
  useEffect$1(() => {
14417
14417
  if (!instantPages || isLoadingData) {
14418
14418
  return;
@@ -14434,7 +14434,12 @@ function ListBox(_ref2) {
14434
14434
  }
14435
14435
 
14436
14436
  const isVertical = listLayout !== 'horizontal';
14437
- const count = layout.qListObject.qSize.qcy;
14437
+ let count = layout.qListObject.qSize.qcy; // Should not allow a count of zero since it will stop executing loadMoreItems
14438
+ // this could happen if a seach returns an empty result
14439
+
14440
+ if (count === 0) {
14441
+ count = 1;
14442
+ }
14438
14443
 
14439
14444
  const getCalculatedHeight = ps => {
14440
14445
  // If values have been filtered in the currently loaded page, we want to
@@ -15108,14 +15113,20 @@ function ListBoxSearch(_ref) {
15108
15113
 
15109
15114
  const onChange = e => {
15110
15115
  setValue(e.target.value);
15111
- model.searchListObjectFor(TREE_PATH, e.target.value);
15116
+
15117
+ if (e.target.value.length === 0) {
15118
+ model.abortListObjectSearch(TREE_PATH);
15119
+ } else {
15120
+ model.searchListObjectFor(TREE_PATH, e.target.value);
15121
+ }
15112
15122
  };
15113
15123
 
15114
15124
  const onKeyDown = e => {
15115
15125
  switch (e.key) {
15116
15126
  case 'Enter':
15117
- model.acceptListObjectSearch(TREE_PATH, true);
15118
- setValue('');
15127
+ // This is disabled to "solve" QB-10955 with the lowest risk
15128
+ // await model.acceptListObjectSearch(TREE_PATH, true);
15129
+ // setValue('');
15119
15130
  break;
15120
15131
 
15121
15132
  case 'Escape':
@@ -24738,7 +24749,7 @@ var enigmaMocker = {exports: {}};
24738
24749
  var enigmaMocker_dev = {exports: {}};
24739
24750
 
24740
24751
  /*
24741
- * @nebula.js/enigma-mocker v3.0.0-alpha1
24752
+ * @nebula.js/enigma-mocker v3.0.0-alpha4
24742
24753
  * Copyright (c) 2022 QlikTech International AB
24743
24754
  * Released under the MIT license.
24744
24755
  */