@nebula.js/stardust 4.9.0 → 5.0.0-alpha.0

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,11 +1,11 @@
1
1
  /*
2
- * @nebula.js/stardust v4.9.0
2
+ * @nebula.js/stardust v5.0.0-alpha.0
3
3
  * Copyright (c) 2023 QlikTech International AB
4
4
  * Released under the MIT license.
5
5
  */
6
6
 
7
7
  import * as React from 'react';
8
- import React__default, { useState as useState$1, useEffect as useEffect$1, forwardRef, useMemo as useMemo$1, useImperativeHandle as useImperativeHandle$1, useReducer, useCallback, useLayoutEffect as useLayoutEffect$1, PureComponent, useRef, useContext, createElement, Component } from 'react';
8
+ import React__default, { useState as useState$1, useEffect as useEffect$1, forwardRef, useMemo as useMemo$1, useImperativeHandle as useImperativeHandle$1, useContext, useReducer, useCallback, useLayoutEffect as useLayoutEffect$1, PureComponent, useRef, createElement, Component } from 'react';
9
9
  import ReactDOM from 'react-dom';
10
10
  import { CacheProvider, ThemeContext as ThemeContext$2 } from '@emotion/react';
11
11
  import { Checkbox, Radio, Typography, FormControlLabel, Box, Grid, Tooltip, Paper, IconButton, styled as styled$4, Popover, MenuList, MenuItem, ListItemIcon, Divider, OutlinedInput, InputAdornment, Badge, List, ListItem, Button, Icon, CircularProgress } from '@mui/material';
@@ -708,26 +708,26 @@ var runtime = {exports: {}};
708
708
  }
709
709
  })(runtime);
710
710
 
711
- function ownKeys(e, r) {
712
- var t = Object.keys(e);
711
+ function ownKeys(object, enumerableOnly) {
712
+ var keys = Object.keys(object);
713
713
  if (Object.getOwnPropertySymbols) {
714
- var o = Object.getOwnPropertySymbols(e);
715
- r && (o = o.filter(function (r) {
716
- return Object.getOwnPropertyDescriptor(e, r).enumerable;
717
- })), t.push.apply(t, o);
718
- }
719
- return t;
720
- }
721
- function _objectSpread2(e) {
722
- for (var r = 1; r < arguments.length; r++) {
723
- var t = null != arguments[r] ? arguments[r] : {};
724
- r % 2 ? ownKeys(Object(t), !0).forEach(function (r) {
725
- _defineProperty(e, r, t[r]);
726
- }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) {
727
- Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r));
714
+ var symbols = Object.getOwnPropertySymbols(object);
715
+ enumerableOnly && (symbols = symbols.filter(function (sym) {
716
+ return Object.getOwnPropertyDescriptor(object, sym).enumerable;
717
+ })), keys.push.apply(keys, symbols);
718
+ }
719
+ return keys;
720
+ }
721
+ function _objectSpread2(target) {
722
+ for (var i = 1; i < arguments.length; i++) {
723
+ var source = null != arguments[i] ? arguments[i] : {};
724
+ i % 2 ? ownKeys(Object(source), !0).forEach(function (key) {
725
+ _defineProperty(target, key, source[key]);
726
+ }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) {
727
+ Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key));
728
728
  });
729
729
  }
730
- return e;
730
+ return target;
731
731
  }
732
732
  function _defineProperty(obj, key, value) {
733
733
  key = _toPropertyKey(key);
@@ -3184,15 +3184,14 @@ function theme$1(resolvedTheme) {
3184
3184
  },
3185
3185
  dataColors() {
3186
3186
  /** @interface Theme~DataColorSpecials */
3187
- return (/** @lends Theme~DataColorSpecials */{
3188
- /** @type {string} */
3189
- primary: resolvedTheme.dataColors.primaryColor,
3190
- /** @type {string} */
3191
- nil: resolvedTheme.dataColors.nullColor,
3192
- /** @type {string} */
3193
- others: resolvedTheme.dataColors.othersColor
3194
- }
3195
- );
3187
+ return /** @lends Theme~DataColorSpecials */{
3188
+ /** @type {string} */
3189
+ primary: resolvedTheme.dataColors.primaryColor,
3190
+ /** @type {string} */
3191
+ nil: resolvedTheme.dataColors.nullColor,
3192
+ /** @type {string} */
3193
+ others: resolvedTheme.dataColors.othersColor
3194
+ };
3196
3195
  },
3197
3196
  uiColor(c, shift) {
3198
3197
  // eslint-disable-next-line no-param-reassign
@@ -3518,7 +3517,6 @@ function resolveVariables(objTree, variables) {
3518
3517
  }
3519
3518
  });
3520
3519
  }
3521
-
3522
3520
  styleResolver.resolveRawTheme = raw => {
3523
3521
  // TODO - validate format
3524
3522
  const c = extend$2(true, {}, raw);
@@ -5670,7 +5668,7 @@ function StyledEngineProvider(props) {
5670
5668
  }
5671
5669
 
5672
5670
  /**
5673
- * @mui/styled-engine v5.14.18
5671
+ * @mui/styled-engine v5.14.19
5674
5672
  *
5675
5673
  * @license MIT
5676
5674
  * This source code is licensed under the MIT license found in the
@@ -6126,51 +6124,25 @@ function borderTransform(value) {
6126
6124
  }
6127
6125
  return `${value}px solid`;
6128
6126
  }
6129
- const border = style$1({
6130
- prop: 'border',
6131
- themeKey: 'borders',
6132
- transform: borderTransform
6133
- });
6134
- const borderTop = style$1({
6135
- prop: 'borderTop',
6136
- themeKey: 'borders',
6137
- transform: borderTransform
6138
- });
6139
- const borderRight = style$1({
6140
- prop: 'borderRight',
6141
- themeKey: 'borders',
6142
- transform: borderTransform
6143
- });
6144
- const borderBottom = style$1({
6145
- prop: 'borderBottom',
6146
- themeKey: 'borders',
6147
- transform: borderTransform
6148
- });
6149
- const borderLeft = style$1({
6150
- prop: 'borderLeft',
6151
- themeKey: 'borders',
6152
- transform: borderTransform
6153
- });
6154
- const borderColor = style$1({
6155
- prop: 'borderColor',
6156
- themeKey: 'palette'
6157
- });
6158
- const borderTopColor = style$1({
6159
- prop: 'borderTopColor',
6160
- themeKey: 'palette'
6161
- });
6162
- const borderRightColor = style$1({
6163
- prop: 'borderRightColor',
6164
- themeKey: 'palette'
6165
- });
6166
- const borderBottomColor = style$1({
6167
- prop: 'borderBottomColor',
6168
- themeKey: 'palette'
6169
- });
6170
- const borderLeftColor = style$1({
6171
- prop: 'borderLeftColor',
6172
- themeKey: 'palette'
6173
- });
6127
+ function createBorderStyle(prop, transform) {
6128
+ return style$1({
6129
+ prop,
6130
+ themeKey: 'borders',
6131
+ transform
6132
+ });
6133
+ }
6134
+ const border = createBorderStyle('border', borderTransform);
6135
+ const borderTop = createBorderStyle('borderTop', borderTransform);
6136
+ const borderRight = createBorderStyle('borderRight', borderTransform);
6137
+ const borderBottom = createBorderStyle('borderBottom', borderTransform);
6138
+ const borderLeft = createBorderStyle('borderLeft', borderTransform);
6139
+ const borderColor = createBorderStyle('borderColor');
6140
+ const borderTopColor = createBorderStyle('borderTopColor');
6141
+ const borderRightColor = createBorderStyle('borderRightColor');
6142
+ const borderBottomColor = createBorderStyle('borderBottomColor');
6143
+ const borderLeftColor = createBorderStyle('borderLeftColor');
6144
+ const outline = createBorderStyle('outline', borderTransform);
6145
+ const outlineColor = createBorderStyle('outlineColor');
6174
6146
 
6175
6147
  // false positive
6176
6148
  // eslint-disable-next-line react/function-component-definition
@@ -6186,7 +6158,7 @@ const borderRadius$1 = props => {
6186
6158
  };
6187
6159
  borderRadius$1.propTypes = {};
6188
6160
  borderRadius$1.filterProps = ['borderRadius'];
6189
- compose(border, borderTop, borderRight, borderBottom, borderLeft, borderColor, borderTopColor, borderRightColor, borderBottomColor, borderLeftColor, borderRadius$1);
6161
+ compose(border, borderTop, borderRight, borderBottom, borderLeft, borderColor, borderTopColor, borderRightColor, borderBottomColor, borderLeftColor, borderRadius$1, outline, outlineColor);
6190
6162
 
6191
6163
  // false positive
6192
6164
  // eslint-disable-next-line react/function-component-definition
@@ -6384,6 +6356,13 @@ const defaultSxConfig = {
6384
6356
  borderLeftColor: {
6385
6357
  themeKey: 'palette'
6386
6358
  },
6359
+ outline: {
6360
+ themeKey: 'borders',
6361
+ transform: borderTransform
6362
+ },
6363
+ outlineColor: {
6364
+ themeKey: 'palette'
6365
+ },
6387
6366
  borderRadius: {
6388
6367
  themeKey: 'shape.borderRadius',
6389
6368
  style: borderRadius$1
@@ -8551,7 +8530,7 @@ function create$3(definition) {
8551
8530
  return cache[key];
8552
8531
  }
8553
8532
 
8554
- const NEBULA_VERSION_HASH = "8934" ;
8533
+ const NEBULA_VERSION_HASH = "117f" ;
8555
8534
  ClassNameGenerator$1.configure(componentName => {
8556
8535
  return "njs-".concat(NEBULA_VERSION_HASH, "-").concat(componentName.replace('Mui', ''));
8557
8536
  });
@@ -8562,9 +8541,49 @@ var InstanceContext = React__default.createContext({
8562
8541
  translator: null,
8563
8542
  constraints: {},
8564
8543
  interactions: {},
8565
- themeApi: null
8544
+ themeApi: null,
8545
+ modelStore: {},
8546
+ selectionStore: {}
8566
8547
  });
8567
8548
 
8549
+ const DEFAULT_INTERACTIONS = {
8550
+ active: true,
8551
+ select: true,
8552
+ passive: true,
8553
+ edit: false
8554
+ };
8555
+ function pickConstraintsOrInteractions(context) {
8556
+ const {
8557
+ constraints = {},
8558
+ interactions = {}
8559
+ } = context;
8560
+ // If some interaction is defined, then we use that
8561
+ if (Object.keys(interactions).length > 0) {
8562
+ return interactions;
8563
+ }
8564
+ const ret = {};
8565
+ Object.keys(constraints).forEach(state => {
8566
+ ret[state] = !constraints[state];
8567
+ });
8568
+ return ret;
8569
+ }
8570
+ function unifyContraintsAndInteractions(context) {
8571
+ const interactions = {};
8572
+ const constraints = {};
8573
+ const definedSettings = pickConstraintsOrInteractions(context);
8574
+ Object.keys(DEFAULT_INTERACTIONS).forEach(state => {
8575
+ if (definedSettings[state] !== undefined) {
8576
+ interactions[state] = definedSettings[state];
8577
+ constraints[state] = !definedSettings[state];
8578
+ } else {
8579
+ interactions[state] = DEFAULT_INTERACTIONS[state];
8580
+ constraints[state] = !DEFAULT_INTERACTIONS[state];
8581
+ }
8582
+ });
8583
+ context.constraints = constraints;
8584
+ context.interactions = interactions;
8585
+ }
8586
+
8568
8587
  var createKeyStore = (function () {
8569
8588
  let initialState = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
8570
8589
  let applyMiddleware = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : () => {};
@@ -8607,169 +8626,97 @@ var createKeyStore = (function () {
8607
8626
  return [useKeyStore, store];
8608
8627
  });
8609
8628
 
8610
- const [useAppSelectionsStore, appSelectionsStore] = createKeyStore({});
8611
- const [useAppModalStore, appModalStore] = createKeyStore({});
8612
- const [useModalObjectStore, modalObjectStore] = createKeyStore({});
8613
-
8614
- /* eslint no-underscore-dangle: 0 */
8615
- function createAppSelections(_ref) {
8616
- let {
8617
- app
8618
- } = _ref;
8619
- const key = "".concat(app.id);
8620
- const end = async function () {
8621
- let accept = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : true;
8622
- const {
8623
- model,
8624
- objectSelections
8625
- } = modalObjectStore.get(key) || {};
8626
- if (model) {
8627
- await model.endSelections(accept);
8628
- modalObjectStore.clear(key);
8629
- objectSelections.emit('deactivated');
8630
- }
8631
- };
8632
- const begin = async _ref2 => {
8633
- var _modalObjectStore$get;
8629
+ function initializeStores$1(appId) {
8630
+ const [useRpcResultStore, rpcResultStore] = createKeyStore({});
8631
+ const [useRpcRequestStore, rpcRequestStore] = createKeyStore({});
8632
+ const [useRpcRequestSessionModelStore, rpcRequestSessionModelStore] = createKeyStore({});
8633
+ const [useRpcRequestModelStore, rpcRequestModelStore] = createKeyStore({});
8634
+ const [useModelChangedStore, modelChangedStore] = createKeyStore({});
8635
+ const [, modelInitializedStore] = createKeyStore({});
8636
+ const modelStoreMiddleware = _ref => {
8634
8637
  let {
8635
- model,
8636
- paths,
8637
- accept = true,
8638
- objectSelections
8639
- } = _ref2;
8640
- // Quick return if it's already in modal
8641
- if (objectSelections === ((_modalObjectStore$get = modalObjectStore.get(key)) === null || _modalObjectStore$get === void 0 ? void 0 : _modalObjectStore$get.objectSelections)) {
8642
- return;
8638
+ type,
8639
+ value: model
8640
+ } = _ref;
8641
+ const initialized = modelInitializedStore.get(model.id);
8642
+ modelInitializedStore.set(model.id, {});
8643
+ const onChanged = () => {
8644
+ rpcRequestStore.clear(model.id);
8645
+ modelChangedStore.set(model.id, {});
8646
+ modelChangedStore.dispatch(true); // Force new state to trigger hooks
8647
+ };
8648
+ const unsubscribe = () => {
8649
+ model.removeListener('changed', onChanged);
8650
+ rpcResultStore.clear(model.id);
8651
+ rpcRequestStore.clear(model.id);
8652
+ rpcRequestSessionModelStore.clear(model.id);
8653
+ rpcRequestModelStore.clear(model.id);
8654
+ modelChangedStore.clear(model.id);
8655
+ modelInitializedStore.clear(model.id);
8656
+ };
8657
+ switch (type) {
8658
+ case 'SET':
8659
+ if (!initialized) {
8660
+ model.on('changed', onChanged);
8661
+ model.once('closed', () => {
8662
+ unsubscribe();
8663
+ });
8664
+ }
8665
+ break;
8643
8666
  }
8644
-
8645
- // If other model is in modal state end it
8646
- end(accept);
8647
-
8648
- // Pending modal
8649
- modalObjectStore.set(key, {
8650
- model,
8651
- objectSelections
8667
+ return unsubscribe;
8668
+ };
8669
+ const [useModelStore, modelStore] = createKeyStore({}, modelStoreMiddleware);
8670
+ const subscribe = model => {
8671
+ const unsubscribe = modelStoreMiddleware({
8672
+ type: 'SET',
8673
+ value: model
8652
8674
  });
8653
- const p = Array.isArray(paths) ? paths : [paths];
8654
- const beginSelections = async skipRetry => {
8655
- try {
8656
- await model.beginSelections(p);
8657
- modalObjectStore.set(key, {
8658
- model,
8659
- objectSelections
8660
- }); // We have a modal
8661
- } catch (err) {
8662
- if (err.code === 6003 && !skipRetry) {
8663
- await app.abortModal(accept);
8664
- beginSelections(true);
8665
- } else {
8666
- modalObjectStore.clear(key); // No modal
8667
- }
8668
- }
8675
+ return () => {
8676
+ unsubscribe();
8677
+ modelStore.clear(model.id);
8669
8678
  };
8670
-
8671
- await beginSelections();
8672
8679
  };
8673
- const appModal = {
8674
- begin,
8675
- end
8676
- };
8677
- appModalStore.set(key, appModal);
8678
-
8679
- /**
8680
- * @class
8681
- * @alias AppSelections
8682
- */
8683
- const appSelections = {
8684
- model: app,
8685
- isInModal() {
8686
- return !!modalObjectStore.get(key);
8687
- },
8688
- isModal(objectSelections) {
8689
- var _modalObjectStore$get2;
8690
- // TODO check model state
8691
- return objectSelections ? ((_modalObjectStore$get2 = modalObjectStore.get(key)) === null || _modalObjectStore$get2 === void 0 ? void 0 : _modalObjectStore$get2.objectSelections) === objectSelections : !!modalObjectStore.get(key);
8692
- },
8693
- forward() {
8694
- return appModal.end().then(() => app.forward());
8695
- },
8696
- back() {
8697
- return appModal.end().then(() => app.back());
8698
- },
8699
- clear() {
8700
- return appModal.end().then(() => app.clearAll());
8701
- },
8702
- clearField(field) {
8703
- let state = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : '$';
8704
- return appModal.end().then(() => app.getField(field, state).then(f => f.clear()));
8705
- }
8680
+ return {
8681
+ subscribe,
8682
+ useModelStore,
8683
+ modelStore,
8684
+ useModelChangedStore,
8685
+ useRpcResultStore,
8686
+ rpcResultStore,
8687
+ useRpcRequestStore,
8688
+ rpcRequestStore,
8689
+ useRpcRequestModelStore,
8690
+ rpcRequestModelStore,
8691
+ useRpcRequestSessionModelStore,
8692
+ rpcRequestSessionModelStore,
8693
+ modelChangedStore,
8694
+ appId
8706
8695
  };
8707
- return appSelections;
8708
- }
8709
- function useAppSelections(app) {
8710
- if (!app.session) {
8711
- // assume the app is mocked if session is undefined
8712
- return [];
8713
- }
8714
- const [appSelectionsStore] = useAppSelectionsStore();
8715
- const key = app ? app.id : null;
8716
- let appSelections = appSelectionsStore.get(key);
8717
- useEffect$1(() => {
8718
- if (!app || appSelections) return;
8719
- appSelections = createAppSelections({
8720
- app
8721
- });
8722
- appSelectionsStore.set(key, appSelections);
8723
- appSelectionsStore.dispatch(true);
8724
- }, [app]);
8725
- return [appSelections];
8726
8696
  }
8727
8697
 
8728
- const DEFAULT_INTERACTIONS = {
8729
- active: true,
8730
- select: true,
8731
- passive: true,
8732
- edit: false
8733
- };
8734
- function pickConstraintsOrInteractions(context) {
8735
- const {
8736
- constraints = {},
8737
- interactions = {}
8738
- } = context;
8739
- // If some interaction is defined, then we use that
8740
- if (Object.keys(interactions).length > 0) {
8741
- return interactions;
8742
- }
8743
- const ret = {};
8744
- Object.keys(constraints).forEach(state => {
8745
- ret[state] = !constraints[state];
8746
- });
8747
- return ret;
8748
- }
8749
- function unifyContraintsAndInteractions(context) {
8750
- const interactions = {};
8751
- const constraints = {};
8752
- const definedSettings = pickConstraintsOrInteractions(context);
8753
- Object.keys(DEFAULT_INTERACTIONS).forEach(state => {
8754
- if (definedSettings[state] !== undefined) {
8755
- interactions[state] = definedSettings[state];
8756
- constraints[state] = !definedSettings[state];
8757
- } else {
8758
- interactions[state] = DEFAULT_INTERACTIONS[state];
8759
- constraints[state] = !DEFAULT_INTERACTIONS[state];
8760
- }
8761
- });
8762
- context.constraints = constraints;
8763
- context.interactions = interactions;
8698
+ function initializeStores(appId) {
8699
+ const [useAppSelectionsStore, appSelectionsStore] = createKeyStore({});
8700
+ const [useAppModalStore, appModalStore] = createKeyStore({});
8701
+ const [useModalObjectStore, modalObjectStore] = createKeyStore({});
8702
+ return {
8703
+ useAppSelectionsStore,
8704
+ useAppModalStore,
8705
+ appSelectionsStore,
8706
+ appModalStore,
8707
+ useModalObjectStore,
8708
+ modalObjectStore,
8709
+ appId
8710
+ };
8764
8711
  }
8765
8712
 
8766
8713
  const NebulaApp = forwardRef((_ref, ref) => {
8767
8714
  let {
8768
8715
  initialContext,
8769
- app,
8770
- renderCallback
8716
+ renderCallback,
8717
+ modelStore,
8718
+ selectionStore
8771
8719
  } = _ref;
8772
- const [appSelections] = useAppSelections(app);
8773
8720
  const [context, setContext] = useState$1(initialContext);
8774
8721
  const [muiThemeName, setMuiThemeName] = useState$1();
8775
8722
  const {
@@ -8789,9 +8736,12 @@ const NebulaApp = forwardRef((_ref, ref) => {
8789
8736
  setComponents([...comps]);
8790
8737
  },
8791
8738
  setMuiThemeName,
8792
- setContext: ctx => setContext(oldContext => JSON.stringify(oldContext) !== JSON.stringify(ctx) ? ctx : oldContext),
8793
- getAppSelections: () => appSelections
8739
+ setContext: ctx => setContext(oldContext => JSON.stringify(oldContext) !== JSON.stringify(ctx) ? ctx : oldContext)
8794
8740
  }), []);
8741
+ if (context) {
8742
+ context.modelStore = modelStore;
8743
+ context.selectionStore = selectionStore;
8744
+ }
8795
8745
  return /*#__PURE__*/React__default.createElement(StyledEngineProvider, {
8796
8746
  injectFirst: true
8797
8747
  }, /*#__PURE__*/React__default.createElement(ThemeProvider, {
@@ -8812,18 +8762,21 @@ function boot(_ref2) {
8812
8762
  const appRef = React__default.createRef();
8813
8763
  const element = document.createElement('div');
8814
8764
  element.style.display = 'none';
8815
- element.setAttribute('data-nebulajs-version', "4.9.0" );
8765
+ element.setAttribute('data-nebulajs-version', "5.0.0-alpha.0" );
8816
8766
  element.setAttribute('data-app-id', app.id);
8817
8767
  document.body.appendChild(element);
8818
8768
  if (context) {
8819
8769
  unifyContraintsAndInteractions(context);
8820
8770
  }
8771
+ const modelStore = initializeStores$1(app.id);
8772
+ const selectionStore = initializeStores(app.id);
8821
8773
  const root = client.createRoot(element);
8822
8774
  root.render( /*#__PURE__*/React__default.createElement(NebulaApp, {
8823
8775
  ref: appRef,
8824
- app: app,
8825
8776
  initialContext: context,
8826
- renderCallback: resolveRender
8777
+ renderCallback: resolveRender,
8778
+ modelStore: modelStore,
8779
+ selectionStore: selectionStore
8827
8780
  }));
8828
8781
  const cells = {};
8829
8782
  const components = [];
@@ -8872,65 +8825,40 @@ function boot(_ref2) {
8872
8825
  }
8873
8826
  appRef.current.setContext(ctx);
8874
8827
  })();
8875
- },
8876
- getAppSelections: async () => {
8877
- await rendered;
8878
- return appRef.current.getAppSelections();
8879
8828
  }
8880
- }, appRef, rendered];
8829
+ }, modelStore, selectionStore, appRef, rendered];
8881
8830
  }
8882
8831
 
8883
- const [useRpcResultStore, rpcResultStore] = createKeyStore({});
8884
- const [useRpcRequestStore, rpcRequestStore] = createKeyStore({});
8885
- const [useRpcRequestSessionModelStore, rpcRequestSessionModelStore] = createKeyStore({});
8886
- const [useRpcRequestModelStore, rpcRequestModelStore] = createKeyStore({});
8887
- const [useModelChangedStore, modelChangedStore] = createKeyStore({});
8888
- const [, modelInitializedStore] = createKeyStore({});
8889
- const modelStoreMiddleware = _ref => {
8890
- let {
8891
- type,
8892
- value: model
8893
- } = _ref;
8894
- const initialized = modelInitializedStore.get(model.id);
8895
- modelInitializedStore.set(model.id, {});
8896
- const onChanged = () => {
8897
- rpcRequestStore.clear(model.id);
8898
- modelChangedStore.set(model.id, {});
8899
- modelChangedStore.dispatch(true); // Force new state to trigger hooks
8900
- };
8901
-
8902
- const unsubscribe = () => {
8903
- model.removeListener('changed', onChanged);
8904
- rpcResultStore.clear(model.id);
8905
- rpcRequestStore.clear(model.id);
8906
- rpcRequestSessionModelStore.clear(model.id);
8907
- rpcRequestModelStore.clear(model.id);
8908
- modelChangedStore.clear(model.id);
8909
- modelInitializedStore.clear(model.id);
8910
- };
8911
- switch (type) {
8912
- case 'SET':
8913
- if (!initialized) {
8914
- model.on('changed', onChanged);
8915
- model.once('closed', () => {
8916
- unsubscribe();
8917
- });
8918
- }
8919
- break;
8920
- }
8921
- return unsubscribe;
8922
- };
8923
- const [useModelStore, modelStore] = createKeyStore({}, modelStoreMiddleware);
8924
- const subscribe = model => {
8925
- const unsubscribe = modelStoreMiddleware({
8926
- type: 'SET',
8927
- value: model
8928
- });
8929
- return () => {
8930
- unsubscribe();
8931
- modelStore.clear(model.id);
8932
- };
8933
- };
8832
+ function useModelStore() {
8833
+ const {
8834
+ useModelStore: useFunc
8835
+ } = useContext(InstanceContext).modelStore;
8836
+ return useFunc();
8837
+ }
8838
+ function useModelChangedStore() {
8839
+ const {
8840
+ useModelChangedStore: useFunc
8841
+ } = useContext(InstanceContext).modelStore;
8842
+ return useFunc();
8843
+ }
8844
+ function useRpcResultStore() {
8845
+ const {
8846
+ useRpcResultStore: useFunc
8847
+ } = useContext(InstanceContext).modelStore;
8848
+ return useFunc();
8849
+ }
8850
+ function useRpcRequestStore() {
8851
+ const {
8852
+ useRpcRequestStore: useFunc
8853
+ } = useContext(InstanceContext).modelStore;
8854
+ return useFunc();
8855
+ }
8856
+ function useRpcRequestSessionModelStore() {
8857
+ const {
8858
+ useRpcRequestSessionModelStore: useFunc
8859
+ } = useContext(InstanceContext).modelStore;
8860
+ return useFunc();
8861
+ }
8934
8862
 
8935
8863
  function useSessionModel(definition, app) {
8936
8864
  const key = app ? "".concat(app.id, "/").concat(JSON.stringify(definition)) : null;
@@ -10058,7 +9986,6 @@ const getMaxFreqWidth = _ref2 => {
10058
9986
  if (frequencyMode === 'P') {
10059
9987
  return sizes.freqMinWidth; // because it will never grow beyond "100.0%"
10060
9988
  }
10061
-
10062
9989
  return sizes.freqMaxWidth;
10063
9990
  };
10064
9991
  const getSelectedStyle = _ref3 => {
@@ -11065,7 +10992,6 @@ function getRowsKeyboardNavigation(_ref) {
11065
10992
  } else {
11066
10993
  return; // propagate to other Esc handler
11067
10994
  }
11068
-
11069
10995
  break;
11070
10996
  case KEYS.HOME:
11071
10997
  focusListItems.setFirst(true);
@@ -11099,7 +11025,6 @@ function getRowsKeyboardNavigation(_ref) {
11099
11025
  return;
11100
11026
  // don't stop propagation since we want to outsource keydown to other handlers.
11101
11027
  }
11102
-
11103
11028
  if (elementToFocus) {
11104
11029
  elementToFocus.focus();
11105
11030
  }
@@ -11265,7 +11190,6 @@ function RowColumn(_ref) {
11265
11190
  if (!cell) {
11266
11191
  return null; // prevent rendering empty rows
11267
11192
  }
11268
-
11269
11193
  const isGridCol = dataLayout === 'grid' && layoutOrder === 'column';
11270
11194
  const label = (_cell$qText = cell === null || cell === void 0 ? void 0 : cell.qText) !== null && _cell$qText !== void 0 ? _cell$qText : '';
11271
11195
  // Search highlights. Split up labelText span into several and add the highlighted class to matching sub-strings.
@@ -14158,7 +14082,6 @@ function ListBox(_ref) {
14158
14082
  if (s.scrollPosition === 'overflowEnd') {
14159
14083
  return; // Do keyScroll.reset() in fetchData() to avoid scrolling to top.
14160
14084
  }
14161
-
14162
14085
  keyScroll.reset();
14163
14086
  }, [keyScroll.state.up, keyScroll.state.down, keyScroll.state.scrollPosition]);
14164
14087
  const {
@@ -15137,6 +15060,128 @@ function ListBoxSearch(_ref2) {
15137
15060
  });
15138
15061
  }
15139
15062
 
15063
+ /* eslint no-underscore-dangle: 0 */
15064
+ function createAppSelections(_ref) {
15065
+ let {
15066
+ app,
15067
+ selectionStore
15068
+ } = _ref;
15069
+ const key = "".concat(app.id);
15070
+ const {
15071
+ modalObjectStore,
15072
+ appModalStore
15073
+ } = selectionStore;
15074
+ const end = async function () {
15075
+ let accept = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : true;
15076
+ const {
15077
+ model,
15078
+ objectSelections
15079
+ } = modalObjectStore.get(key) || {};
15080
+ if (model) {
15081
+ await model.endSelections(accept);
15082
+ modalObjectStore.clear(key);
15083
+ objectSelections.emit('deactivated');
15084
+ }
15085
+ };
15086
+ const begin = async _ref2 => {
15087
+ var _modalObjectStore$get;
15088
+ let {
15089
+ model,
15090
+ paths,
15091
+ accept = true,
15092
+ objectSelections
15093
+ } = _ref2;
15094
+ // Quick return if it's already in modal
15095
+ if (objectSelections === ((_modalObjectStore$get = modalObjectStore.get(key)) === null || _modalObjectStore$get === void 0 ? void 0 : _modalObjectStore$get.objectSelections)) {
15096
+ return;
15097
+ }
15098
+
15099
+ // If other model is in modal state end it
15100
+ end(accept);
15101
+
15102
+ // Pending modal
15103
+ modalObjectStore.set(key, {
15104
+ model,
15105
+ objectSelections
15106
+ });
15107
+ const p = Array.isArray(paths) ? paths : [paths];
15108
+ const beginSelections = async skipRetry => {
15109
+ try {
15110
+ await model.beginSelections(p);
15111
+ modalObjectStore.set(key, {
15112
+ model,
15113
+ objectSelections
15114
+ }); // We have a modal
15115
+ } catch (err) {
15116
+ if (err.code === 6003 && !skipRetry) {
15117
+ await app.abortModal(accept);
15118
+ beginSelections(true);
15119
+ } else {
15120
+ modalObjectStore.clear(key); // No modal
15121
+ }
15122
+ }
15123
+ };
15124
+ await beginSelections();
15125
+ };
15126
+ const appModal = {
15127
+ begin,
15128
+ end
15129
+ };
15130
+ appModalStore.set(key, appModal);
15131
+
15132
+ /**
15133
+ * @class
15134
+ * @alias AppSelections
15135
+ */
15136
+ const appSelections = {
15137
+ model: app,
15138
+ isInModal() {
15139
+ return !!modalObjectStore.get(key);
15140
+ },
15141
+ isModal(objectSelections) {
15142
+ var _modalObjectStore$get2;
15143
+ // TODO check model state
15144
+ return objectSelections ? ((_modalObjectStore$get2 = modalObjectStore.get(key)) === null || _modalObjectStore$get2 === void 0 ? void 0 : _modalObjectStore$get2.objectSelections) === objectSelections : !!modalObjectStore.get(key);
15145
+ },
15146
+ forward() {
15147
+ return appModal.end().then(() => app.forward());
15148
+ },
15149
+ back() {
15150
+ return appModal.end().then(() => app.back());
15151
+ },
15152
+ clear() {
15153
+ return appModal.end().then(() => app.clearAll());
15154
+ },
15155
+ clearField(field) {
15156
+ let state = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : '$';
15157
+ return appModal.end().then(() => app.getField(field, state).then(f => f.clear()));
15158
+ }
15159
+ };
15160
+ return appSelections;
15161
+ }
15162
+ function useAppSelections(app) {
15163
+ if (!app.session) {
15164
+ // assume the app is mocked if session is undefined
15165
+ return [];
15166
+ }
15167
+ const {
15168
+ selectionStore
15169
+ } = useContext(InstanceContext);
15170
+ const [appSelectionsStore] = selectionStore.useAppSelectionsStore();
15171
+ const key = app ? app.id : null;
15172
+ let appSelections = appSelectionsStore.get(key);
15173
+ useEffect$1(() => {
15174
+ if (!app || appSelections) return;
15175
+ appSelections = createAppSelections({
15176
+ app,
15177
+ selectionStore
15178
+ });
15179
+ appSelectionsStore.set(key, appSelections);
15180
+ appSelectionsStore.dispatch(true);
15181
+ }, [app]);
15182
+ return [appSelections];
15183
+ }
15184
+
15140
15185
  function eventmixin (obj) {
15141
15186
  /* eslint no-param-reassign: 0 */
15142
15187
  Object.keys(EventEmitter$1.prototype).forEach(key => {
@@ -15380,7 +15425,9 @@ function useObjectSelections(app, model, elements, options) {
15380
15425
  const elementsArr = Array.isArray(elements) ? elements : [elements];
15381
15426
  const [appSelections] = useAppSelections(app);
15382
15427
  const [layout] = useLayout$1(model);
15383
- const [appModalStore] = useAppModalStore();
15428
+ const {
15429
+ appModalStore
15430
+ } = useContext(InstanceContext).selectionStore;
15384
15431
  const appModal = appModalStore.get(app.id);
15385
15432
  const [objectSelections, setObjectSelections] = useState$1();
15386
15433
  useEffect$1(() => {
@@ -16727,7 +16774,6 @@ class Color {
16727
16774
  this._lumi = 0.299 * this._r + 0.587 * this._g + 0.114 * this._b; // option 2
16728
16775
  // this._lumi = Math.sqrt( 0.241 * this._r * this._r + 0.691 * this._g * this._g + 0.068 * this._b * this._b ); // option 3
16729
16776
  }
16730
-
16731
16777
  return this._lumi;
16732
16778
  }
16733
16779
 
@@ -17780,7 +17826,6 @@ function OneField(_ref) {
17780
17826
  segments.forEach((s, i) => {
17781
17827
  s.offset = i ? segments[i - 1].offset + segments[i - 1].ratio : 0; // eslint-disable-line
17782
17828
  });
17783
-
17784
17829
  let Header = null;
17785
17830
  let Icon = null;
17786
17831
  let SegmentsIndicator = null;
@@ -18233,7 +18278,9 @@ function SelectedFields(_ref) {
18233
18278
  items: [],
18234
18279
  more: []
18235
18280
  });
18236
- const [modalObjectStore] = useModalObjectStore();
18281
+ const {
18282
+ modalObjectStore
18283
+ } = useContext(InstanceContext).selectionStore;
18237
18284
  const [containerRef, containerRect] = useRect$1();
18238
18285
  const [maxItems, setMaxItems] = useState$1(0);
18239
18286
  const isInListboxPopover = () => {
@@ -19011,7 +19058,6 @@ function getListboxContainerKeyboardNavigation(_ref) {
19011
19058
  if (!event.target.classList.contains('listbox-container')) {
19012
19059
  break; // don't mess with keydown handlers within the listbox (e.g. row seletion)
19013
19060
  }
19014
-
19015
19061
  keyboard.focus();
19016
19062
  prevent();
19017
19063
  break;
@@ -19196,7 +19242,6 @@ function getContainerPadding(_ref) {
19196
19242
  } else {
19197
19243
  containerPadding = undefined; // to prevent overriding any default padding
19198
19244
  }
19199
-
19200
19245
  return containerPadding;
19201
19246
  }
19202
19247
 
@@ -19268,7 +19313,6 @@ const Title = styled$1(Typography)(_ref3 => {
19268
19313
  paddingRight: '1px' // make place for italic font style
19269
19314
  });
19270
19315
  });
19271
-
19272
19316
  const isModal = _ref4 => {
19273
19317
  var _app$isInModalSelecti, _app$isInModalSelecti2;
19274
19318
  let {
@@ -20143,7 +20187,6 @@ function ListBoxWrapper(_ref) {
20143
20187
  frequencyMode: getFrequencyModeLetter(options.frequencyMode) // stick to letter option hereafter
20144
20188
  });
20145
20189
  }
20146
-
20147
20190
  const [changeCount, setChangeCount] = useState$1(0);
20148
20191
  useEffect$1(() => {
20149
20192
  if (changeCount) {
@@ -20545,7 +20588,6 @@ async function populateData(_ref, halo) {
20545
20588
  {
20546
20589
  console.warn('Attempting to add fields to an object without a specified data target'); // eslint-disable-line no-console
20547
20590
  }
20548
-
20549
20591
  return;
20550
20592
  }
20551
20593
  const {
@@ -20644,7 +20686,6 @@ const getValue = (data, reference, defaultValue) => {
20644
20686
  if (step === '') {
20645
20687
  continue; // eslint-disable-line no-continue
20646
20688
  }
20647
-
20648
20689
  if (dataContainer[step] === undefined || dataContainer[step] === null) {
20649
20690
  return defaultValue;
20650
20691
  }
@@ -20814,7 +20855,6 @@ function copyPropertyOrSetDefault(propertyName, source, target, defaultValue) {
20814
20855
  function getOthersLabel() {
20815
20856
  return 'Others'; // TODO: translator.get('properties.dimensionLimits.others')
20816
20857
  }
20817
-
20818
20858
  function createDefaultDimension(dimensionDef, dimensionProperties) {
20819
20859
  const def = extend$2(true, {}, dimensionProperties, dimensionDef);
20820
20860
  if (!utils.getValue(def, 'qOtherTotalSpec.qOtherCounted')) {
@@ -21340,7 +21380,6 @@ const getDefaultExportPropertiesFn = path => {
21340
21380
  }
21341
21381
  return undefined; // TODO: add listbox and other
21342
21382
  };
21343
-
21344
21383
  const getExportPropertiesFnc = qae => {
21345
21384
  if (qae.exportProperties) {
21346
21385
  return qae.exportProperties;
@@ -21355,7 +21394,6 @@ const getDefaultImportPropertiesFnc = path => {
21355
21394
  }
21356
21395
  return undefined; // TODO: add listbox and other
21357
21396
  };
21358
-
21359
21397
  const getImportPropertiesFnc = qae => {
21360
21398
  if (qae.importProperties) {
21361
21399
  return qae.importProperties;
@@ -23393,7 +23431,6 @@ function flushMacro(hooks) {
23393
23431
  hooks.macro = null;
23394
23432
  maybeEndChain(hooks); // eslint-disable-line no-use-before-define
23395
23433
  }
23396
-
23397
23434
  function maybeEndChain(hooks) {
23398
23435
  if (hooks.pendingPromises.length || hooks.micro || hooks.macro) {
23399
23436
  return;
@@ -24930,7 +24967,6 @@ const resolveValue = (data, reference, defaultValue) => {
24930
24967
  if (steps[i] === '') {
24931
24968
  continue; // eslint-disable-line no-continue
24932
24969
  }
24933
-
24934
24970
  if (typeof dataContainer[steps[i]] === 'undefined') {
24935
24971
  return defaultValue;
24936
24972
  }
@@ -25406,7 +25442,6 @@ function viz() {
25406
25442
  // resize() {},
25407
25443
  // show() {},
25408
25444
  };
25409
-
25410
25445
  return api;
25411
25446
  }
25412
25447
 
@@ -25468,7 +25503,7 @@ async function init(model, optional, halo, initialError) {
25468
25503
  * };
25469
25504
  * nebbie.render(createConfig);
25470
25505
  */
25471
- async function createSessionObject(_ref, halo) {
25506
+ async function createSessionObject(_ref, halo, store) {
25472
25507
  let {
25473
25508
  type,
25474
25509
  version,
@@ -25481,6 +25516,10 @@ async function createSessionObject(_ref, halo) {
25481
25516
  } = _ref;
25482
25517
  let mergedProps = {};
25483
25518
  const children = [];
25519
+ const {
25520
+ modelStore,
25521
+ subscribe
25522
+ } = store;
25484
25523
  let error;
25485
25524
  try {
25486
25525
  const t = halo.types.get({
@@ -25512,7 +25551,6 @@ async function createSessionObject(_ref, halo) {
25512
25551
  };
25513
25552
  // console.error(e); // eslint-disable-line
25514
25553
  }
25515
-
25516
25554
  const model = await halo.app.createSessionObject(mergedProps);
25517
25555
  if (children.length > 0) {
25518
25556
  await model.setFullPropertyTree({
@@ -25546,7 +25584,7 @@ async function createSessionObject(_ref, halo) {
25546
25584
  * @property {EngineAPI.IGenericObjectProperties=} properties
25547
25585
  */
25548
25586
 
25549
- async function createObject(_ref, halo, generateOnly) {
25587
+ async function createObject(_ref, halo, generateOnly, store) {
25550
25588
  let {
25551
25589
  type,
25552
25590
  version,
@@ -25556,6 +25594,9 @@ async function createObject(_ref, halo, generateOnly) {
25556
25594
  } = _ref;
25557
25595
  let mergedProps = {};
25558
25596
  const children = [];
25597
+ const {
25598
+ modelStore
25599
+ } = store;
25559
25600
  // let error;
25560
25601
  try {
25561
25602
  const t = halo.types.get({
@@ -25591,7 +25632,6 @@ async function createObject(_ref, halo, generateOnly) {
25591
25632
  }
25592
25633
  // console.error(e); // eslint-disable-line
25593
25634
  }
25594
-
25595
25635
  if (!generateOnly) {
25596
25636
  const model = await halo.app.createObject(mergedProps);
25597
25637
  if (children.length > 0) {
@@ -25606,13 +25646,17 @@ async function createObject(_ref, halo, generateOnly) {
25606
25646
  return mergedProps;
25607
25647
  }
25608
25648
 
25609
- async function getObject$1(_ref, halo) {
25649
+ async function getObject$1(_ref, halo, store) {
25610
25650
  let {
25611
25651
  id,
25612
25652
  options,
25613
25653
  plugins,
25614
25654
  element
25615
25655
  } = _ref;
25656
+ const {
25657
+ modelStore,
25658
+ rpcRequestModelStore
25659
+ } = store;
25616
25660
  const key = "".concat(id);
25617
25661
  let rpc = rpcRequestModelStore.get(key);
25618
25662
  if (!rpc) {
@@ -25689,7 +25733,8 @@ function Sheet(_ref) {
25689
25733
  } = halo;
25690
25734
  const [layout] = useLayout$1(model);
25691
25735
  const {
25692
- theme: themeName
25736
+ theme: themeName,
25737
+ modelStore
25693
25738
  } = useContext(InstanceContext);
25694
25739
  const [cells, setCells] = useState$1([]);
25695
25740
  const [bgColor, setBgColor] = useState$1(undefined);
@@ -25734,7 +25779,7 @@ function Sheet(_ref) {
25734
25779
  }
25735
25780
  const vs = await getObject$1({
25736
25781
  id: c.name
25737
- }, halo);
25782
+ }, halo, modelStore);
25738
25783
  return {
25739
25784
  model: vs.model,
25740
25785
  id: c.name,
@@ -25968,13 +26013,17 @@ async function initSheet(model, optional, halo, initialError) {
25968
26013
  return api;
25969
26014
  }
25970
26015
 
25971
- async function getObject(_ref, halo) {
26016
+ async function getObject(_ref, halo, store) {
25972
26017
  let {
25973
26018
  id,
25974
26019
  options,
25975
26020
  plugins,
25976
26021
  element
25977
26022
  } = _ref;
26023
+ const {
26024
+ modelStore,
26025
+ rpcRequestModelStore
26026
+ } = store;
25978
26027
  const key = "".concat(id);
25979
26028
  let rpc = rpcRequestModelStore.get(key);
25980
26029
  if (!rpc) {
@@ -26003,15 +26052,14 @@ function flagsFn () {
26003
26052
  * @interface Flags
26004
26053
  */
26005
26054
 
26006
- return (/** @lends Flags */{
26007
- /**
26008
- * Checks whether the specified flag is enabled.
26009
- * @param {string} flag - The value flag to check.
26010
- * @returns {boolean} True if the specified flag is enabled, false otherwise.
26011
- */
26012
- isEnabled: f => flags[f] === true
26013
- }
26014
- );
26055
+ return /** @lends Flags */{
26056
+ /**
26057
+ * Checks whether the specified flag is enabled.
26058
+ * @param {string} flag - The value flag to check.
26059
+ * @returns {boolean} True if the specified flag is enabled, false otherwise.
26060
+ */
26061
+ isEnabled: f => flags[f] === true
26062
+ };
26015
26063
  }
26016
26064
 
26017
26065
  var iterator;
@@ -26574,7 +26622,6 @@ class LRUCache {
26574
26622
  this[LRU_LIST] = new Yallist(); // list of items in order of use recency
26575
26623
  this[LENGTH] = 0; // length of items in the list
26576
26624
  }
26577
-
26578
26625
  dump() {
26579
26626
  return this[LRU_LIST].map(hit => isStale(this, hit) ? false : {
26580
26627
  k: hit.key,
@@ -27933,7 +27980,6 @@ async function load(name, version, _ref, loader) {
27933
27980
  {
27934
27981
  console.warn(e); // eslint-disable-line no-console
27935
27982
  }
27936
-
27937
27983
  throw new Error("Failed to load visualization: '".concat(sKey, "'"));
27938
27984
  });
27939
27985
  }
@@ -28066,7 +28112,6 @@ function create(_ref) {
28066
28112
  {
28067
28113
  console.warn("Visualization ".concat(name, " is not registered. Adding it now.")); // eslint-disable-line no-console
28068
28114
  }
28069
-
28070
28115
  this.register({
28071
28116
  name,
28072
28117
  version
@@ -28077,7 +28122,6 @@ function create(_ref) {
28077
28122
  {
28078
28123
  console.warn("Version ".concat(version, " of ").concat(name, " is not registered. Falling back to version ").concat(versionToUse)); // eslint-disable-line no-console
28079
28124
  }
28080
-
28081
28125
  version = versionToUse;
28082
28126
  }
28083
28127
  return tc[name].get(version) || p.get(typeInfo);
@@ -28287,7 +28331,7 @@ function nuked() {
28287
28331
  let currentContext = _objectSpread2(_objectSpread2({}, configuration.context), {}, {
28288
28332
  translator: locale.translator
28289
28333
  });
28290
- const [root] = boot({
28334
+ const [root, modelStore] = boot({
28291
28335
  app,
28292
28336
  context: currentContext
28293
28337
  });
@@ -28313,7 +28357,6 @@ function nuked() {
28313
28357
  translator: locale.translator,
28314
28358
  nebbie: null // actual value is set further down
28315
28359
  };
28316
-
28317
28360
  const halo = {
28318
28361
  app,
28319
28362
  root,
@@ -28381,9 +28424,9 @@ function nuked() {
28381
28424
  render: async cfg => {
28382
28425
  await currentThemePromise;
28383
28426
  if (cfg.id) {
28384
- return getObject(cfg, halo);
28427
+ return getObject(cfg, halo, modelStore);
28385
28428
  }
28386
- return createSessionObject(cfg, halo);
28429
+ return createSessionObject(cfg, halo, modelStore);
28387
28430
  },
28388
28431
  /**
28389
28432
  * Creates a visualization model
@@ -28399,7 +28442,7 @@ function nuked() {
28399
28442
  * }
28400
28443
  * );
28401
28444
  */
28402
- create: async cfg => createObject(cfg, halo, false),
28445
+ create: async cfg => createObject(cfg, halo, false, modelStore),
28403
28446
  /**
28404
28447
  * Generates properties for a visualization object
28405
28448
  * @param {CreateConfig} cfg The create configuration.
@@ -28462,7 +28505,6 @@ function nuked() {
28462
28505
  */
28463
28506
  selections: async () => {
28464
28507
  if (!selectionsApi) {
28465
- // const appSelections = await root.getAppSelections(); // Don't expose this for now
28466
28508
  selectionsApi = /** @lends AppSelections# */{
28467
28509
  /**
28468
28510
  * Mounts the app selection UI into the provided HTMLElement.
@@ -28475,7 +28517,6 @@ function nuked() {
28475
28517
  {
28476
28518
  console.error('Already mounted'); // eslint-disable-line no-console
28477
28519
  }
28478
-
28479
28520
  return;
28480
28521
  }
28481
28522
  selectionsComponentReference = mount({