@nebula.js/stardust 3.0.0-alpha1 → 3.0.0-alpha2
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 +20 -13
- package/core/esm/dev.js.map +1 -1
- package/core/esm/index.js +2 -2
- package/core/esm/index.js.map +1 -1
- package/dist/stardust.dev.js +20 -13
- package/dist/stardust.dev.js.map +1 -1
- package/dist/stardust.js +3 -3
- package/dist/stardust.js.map +1 -1
- package/package.json +9 -9
package/dist/stardust.dev.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/*
|
|
2
|
-
* @nebula.js/stardust v3.0.0-
|
|
2
|
+
* @nebula.js/stardust v3.0.0-alpha2
|
|
3
3
|
* Copyright (c) 2022 QlikTech International AB
|
|
4
4
|
* Released under the MIT license.
|
|
5
5
|
*/
|
|
@@ -16197,7 +16197,7 @@
|
|
|
16197
16197
|
return cache[key];
|
|
16198
16198
|
}
|
|
16199
16199
|
|
|
16200
|
-
const NEBULA_VERSION_HASH = "
|
|
16200
|
+
const NEBULA_VERSION_HASH = "9c10" ;
|
|
16201
16201
|
ClassNameGenerator.configure(componentName => {
|
|
16202
16202
|
|
|
16203
16203
|
return "njs-".concat(NEBULA_VERSION_HASH, "-").concat(componentName.replace('Mui', ''));
|
|
@@ -16770,7 +16770,7 @@
|
|
|
16770
16770
|
const appRef = React.createRef();
|
|
16771
16771
|
const element = document.createElement('div');
|
|
16772
16772
|
element.style.display = 'none';
|
|
16773
|
-
element.setAttribute('data-nebulajs-version', "3.0.0-
|
|
16773
|
+
element.setAttribute('data-nebulajs-version', "3.0.0-alpha2" );
|
|
16774
16774
|
element.setAttribute('data-app-id', app.id);
|
|
16775
16775
|
document.body.appendChild(element);
|
|
16776
16776
|
ReactDOM.render( /*#__PURE__*/React.createElement(NebulaApp, {
|
|
@@ -31645,7 +31645,8 @@
|
|
|
31645
31645
|
paddingRight: '8px'
|
|
31646
31646
|
},
|
|
31647
31647
|
["&.".concat(classes$a.barContainer)]: {
|
|
31648
|
-
|
|
31648
|
+
height: '100%',
|
|
31649
|
+
display: 'inline-block'
|
|
31649
31650
|
},
|
|
31650
31651
|
["& .".concat(classes$a.bar)]: {
|
|
31651
31652
|
border: "".concat(barBorderWidthPx, "px solid"),
|
|
@@ -31681,8 +31682,7 @@
|
|
|
31681
31682
|
let {
|
|
31682
31683
|
index,
|
|
31683
31684
|
style,
|
|
31684
|
-
data
|
|
31685
|
-
column = false
|
|
31685
|
+
data
|
|
31686
31686
|
} = _ref3;
|
|
31687
31687
|
const {
|
|
31688
31688
|
onClick,
|
|
@@ -31691,6 +31691,7 @@
|
|
|
31691
31691
|
onMouseEnter,
|
|
31692
31692
|
pages,
|
|
31693
31693
|
isLocked,
|
|
31694
|
+
column = false,
|
|
31694
31695
|
checkboxes = false,
|
|
31695
31696
|
dense = false,
|
|
31696
31697
|
frequencyMode = 'N',
|
|
@@ -34467,7 +34468,7 @@
|
|
|
34467
34468
|
* user interact outside of passed element ref.
|
|
34468
34469
|
*/
|
|
34469
34470
|
|
|
34470
|
-
function useConfirmUnfocus(ref, selections) {
|
|
34471
|
+
function useConfirmUnfocus(ref, selections, shouldConfirmOnBlur) {
|
|
34471
34472
|
const [_isConfirmed, _setIsConfirmed] = react.exports.useState(false); // Wrap state in ref to use inside eventListener callback
|
|
34472
34473
|
|
|
34473
34474
|
const isConfirmedRef = react.exports.useRef(_isConfirmed);
|
|
@@ -34479,6 +34480,8 @@
|
|
|
34479
34480
|
};
|
|
34480
34481
|
|
|
34481
34482
|
react.exports.useEffect(() => {
|
|
34483
|
+
if (!shouldConfirmOnBlur) return undefined;
|
|
34484
|
+
|
|
34482
34485
|
const handleEvent = event => {
|
|
34483
34486
|
const interactInside = ref.current && ref.current.contains(event.target);
|
|
34484
34487
|
const isConfirmed = isConfirmedRef.current;
|
|
@@ -34497,7 +34500,7 @@
|
|
|
34497
34500
|
document.removeEventListener('mousedown', handleEvent);
|
|
34498
34501
|
document.removeEventListener('keydown', handleEvent);
|
|
34499
34502
|
};
|
|
34500
|
-
}, [ref, selections]);
|
|
34503
|
+
}, [ref, selections, shouldConfirmOnBlur]);
|
|
34501
34504
|
}
|
|
34502
34505
|
|
|
34503
34506
|
const PREFIX$4 = 'ListBoxInline';
|
|
@@ -34539,7 +34542,8 @@
|
|
|
34539
34542
|
showGray = true,
|
|
34540
34543
|
sortByState = 1,
|
|
34541
34544
|
scrollState = undefined,
|
|
34542
|
-
setCount = undefined
|
|
34545
|
+
setCount = undefined,
|
|
34546
|
+
shouldConfirmOnBlur = undefined
|
|
34543
34547
|
} = options;
|
|
34544
34548
|
let {
|
|
34545
34549
|
frequencyMode,
|
|
@@ -34694,7 +34698,7 @@
|
|
|
34694
34698
|
}
|
|
34695
34699
|
}, [selections]);
|
|
34696
34700
|
const listBoxRef = react.exports.useRef(null);
|
|
34697
|
-
useConfirmUnfocus(listBoxRef, selections);
|
|
34701
|
+
useConfirmUnfocus(listBoxRef, selections, shouldConfirmOnBlur);
|
|
34698
34702
|
react.exports.useEffect(() => {
|
|
34699
34703
|
if (!searchContainer || !searchContainer.current) {
|
|
34700
34704
|
return;
|
|
@@ -34720,7 +34724,9 @@
|
|
|
34720
34724
|
const counts = layout.qListObject.qDimensionInfo.qStateCounts;
|
|
34721
34725
|
const hasSelections = counts.qSelected + counts.qSelectedExcluded + counts.qLocked + counts.qLockedExcluded > 0;
|
|
34722
34726
|
const searchVisible = (search === true || search === 'toggle' && showSearch) && !selectDisabled();
|
|
34723
|
-
const
|
|
34727
|
+
const searchHeight = dense ? 27 : 40;
|
|
34728
|
+
const extraheight = dense ? 39 : 49;
|
|
34729
|
+
const minHeight = 49 + (searchVisible ? searchHeight : 0) + extraheight;
|
|
34724
34730
|
|
|
34725
34731
|
const onShowSearch = () => {
|
|
34726
34732
|
const newValue = !showSearch;
|
|
@@ -37213,7 +37219,7 @@
|
|
|
37213
37219
|
|
|
37214
37220
|
load(layout.visualization, withVersion);
|
|
37215
37221
|
return () => {};
|
|
37216
|
-
}, [types, state.sn, model, layout, appLayout, language]); // Long running query
|
|
37222
|
+
}, [types, state.sn, model, selections, layout, appLayout, language]); // Long running query
|
|
37217
37223
|
|
|
37218
37224
|
react.exports.useEffect(() => {
|
|
37219
37225
|
if (!validating) {
|
|
@@ -42000,6 +42006,7 @@
|
|
|
42000
42006
|
* @property {{setScrollPos:function(number):void, initScrollPos:number}} [options.scrollState=] Object including a setScrollPos function that sets current scroll position index. A initial scroll position index.
|
|
42001
42007
|
* @property {number=} [options.sortByState=1] Sort by state, detault 1 = sort descending, 0 = no sorting, -1 sort ascending.
|
|
42002
42008
|
* @property {function(number):void} [options.setCount=] A function that gets called with the length of the data in the Listbox.
|
|
42009
|
+
* @property {boolean} [options.shouldConfirmOnBlur=] A boolean that determines if the listbox should actively confirm selections on blur events.
|
|
42003
42010
|
*/
|
|
42004
42011
|
|
|
42005
42012
|
/**
|
|
@@ -42425,7 +42432,7 @@
|
|
|
42425
42432
|
var enigmaMocker_dev = {exports: {}};
|
|
42426
42433
|
|
|
42427
42434
|
/*
|
|
42428
|
-
* @nebula.js/enigma-mocker v3.0.0-
|
|
42435
|
+
* @nebula.js/enigma-mocker v3.0.0-alpha1
|
|
42429
42436
|
* Copyright (c) 2022 QlikTech International AB
|
|
42430
42437
|
* Released under the MIT license.
|
|
42431
42438
|
*/
|